<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html lang="en">

<head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  <title>LCOV - ohos_codeCoverage.info - prebuilts/clang/ohos/linux-x86_64/llvm/include/libcxx-ohos/include/c++/v1/__string</title>
  <link rel="stylesheet" type="text/css" href="../../../../../../../../../../gcov.css">
</head>

<body>

  <table width="100%" border=0 cellspacing=0 cellpadding=0>
    <tr><td class="title">LCOV - code coverage report</td></tr>
    <tr><td class="ruler"><img src="../../../../../../../../../../glass.png" width=3 height=3 alt=""></td></tr>

    <tr>
      <td width="100%">
        <table cellpadding=1 border=0 width="100%">
          <tr>
            <td width="10%" class="headerItem">Current view:</td>
            <td width="35%" class="headerValue"><a href="../../../../../../../../../../index.html">top level</a> - <a href="index.html">prebuilts/clang/ohos/linux-x86_64/llvm/include/libcxx-ohos/include/c++/v1</a> - __string<span style="font-size: 80%;"> (source / <a href="__string.func-sort-c.html">functions</a>)</span></td>
            <td width="5%"></td>
            <td width="15%"></td>
            <td width="10%" class="headerCovTableHead">Hit</td>
            <td width="10%" class="headerCovTableHead">Total</td>
            <td width="15%" class="headerCovTableHead">Coverage</td>
          </tr>
          <tr>
            <td class="headerItem">Test:</td>
            <td class="headerValue">ohos_codeCoverage.info</td>
            <td></td>
            <td class="headerItem">Lines:</td>
            <td class="headerCovTableEntry">16</td>
            <td class="headerCovTableEntry">23</td>
            <td class="headerCovTableEntryLo">69.6 %</td>
          </tr>
          <tr>
            <td class="headerItem">Date:</td>
            <td class="headerValue">2022-08-23 10:37:51</td>
            <td></td>
            <td class="headerItem">Functions:</td>
            <td class="headerCovTableEntry">4</td>
            <td class="headerCovTableEntry">6</td>
            <td class="headerCovTableEntryLo">66.7 %</td>
          </tr>
          <tr>
            <td></td>
            <td></td>
            <td></td>
            <td class="headerItem">Branches:</td>
            <td class="headerCovTableEntry">0</td>
            <td class="headerCovTableEntry">0</td>
            <td class="headerCovTableEntryHi">-</td>
          </tr>
          <tr><td><img src="../../../../../../../../../../glass.png" width=3 height=3 alt=""></td></tr>
        </table>
      </td>
    </tr>

    <tr><td class="ruler"><img src="../../../../../../../../../../glass.png" width=3 height=3 alt=""></td></tr>
  </table>

  <table cellpadding=0 cellspacing=0 border=0>
    <tr>
      <td><br></td>
    </tr>
    <tr>
      <td>
<pre class="sourceHeading">           Branch data     Line data    Source code</pre>
<pre class="source">
<a name="1"><span class="lineNum">       1 </span>                :            : // -*- C++ -*-</a>
<a name="2"><span class="lineNum">       2 </span>                :            : //===-------------------------- __string ----------------------------------===//</a>
<a name="3"><span class="lineNum">       3 </span>                :            : //</a>
<a name="4"><span class="lineNum">       4 </span>                :            : // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.</a>
<a name="5"><span class="lineNum">       5 </span>                :            : // See https://llvm.org/LICENSE.txt for license information.</a>
<a name="6"><span class="lineNum">       6 </span>                :            : // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception</a>
<a name="7"><span class="lineNum">       7 </span>                :            : //</a>
<a name="8"><span class="lineNum">       8 </span>                :            : //===----------------------------------------------------------------------===//</a>
<a name="9"><span class="lineNum">       9 </span>                :            : </a>
<a name="10"><span class="lineNum">      10 </span>                :            : #ifndef _LIBCPP___STRING</a>
<a name="11"><span class="lineNum">      11 </span>                :            : #define _LIBCPP___STRING</a>
<a name="12"><span class="lineNum">      12 </span>                :            : </a>
<a name="13"><span class="lineNum">      13 </span>                :            : /*</a>
<a name="14"><span class="lineNum">      14 </span>                :            :     string synopsis</a>
<a name="15"><span class="lineNum">      15 </span>                :            : </a>
<a name="16"><span class="lineNum">      16 </span>                :            : namespace std</a>
<a name="17"><span class="lineNum">      17 </span>                :            : {</a>
<a name="18"><span class="lineNum">      18 </span>                :            : </a>
<a name="19"><span class="lineNum">      19 </span>                :            : template &lt;class charT&gt;</a>
<a name="20"><span class="lineNum">      20 </span>                :            : struct char_traits</a>
<a name="21"><span class="lineNum">      21 </span>                :            : {</a>
<a name="22"><span class="lineNum">      22 </span>                :            :     typedef charT     char_type;</a>
<a name="23"><span class="lineNum">      23 </span>                :            :     typedef ...       int_type;</a>
<a name="24"><span class="lineNum">      24 </span>                :            :     typedef streamoff off_type;</a>
<a name="25"><span class="lineNum">      25 </span>                :            :     typedef streampos pos_type;</a>
<a name="26"><span class="lineNum">      26 </span>                :            :     typedef mbstate_t state_type;</a>
<a name="27"><span class="lineNum">      27 </span>                :            : </a>
<a name="28"><span class="lineNum">      28 </span>                :            :     static constexpr void assign(char_type&amp; c1, const char_type&amp; c2) noexcept;</a>
<a name="29"><span class="lineNum">      29 </span>                :            :     static constexpr bool eq(char_type c1, char_type c2) noexcept;</a>
<a name="30"><span class="lineNum">      30 </span>                :            :     static constexpr bool lt(char_type c1, char_type c2) noexcept;</a>
<a name="31"><span class="lineNum">      31 </span>                :            : </a>
<a name="32"><span class="lineNum">      32 </span>                :            :     static constexpr int    compare(const char_type* s1, const char_type* s2, size_t n);</a>
<a name="33"><span class="lineNum">      33 </span>                :            :     static constexpr size_t length(const char_type* s);</a>
<a name="34"><span class="lineNum">      34 </span>                :            :     static constexpr const char_type*</a>
<a name="35"><span class="lineNum">      35 </span>                :            :                             find(const char_type* s, size_t n, const char_type&amp; a);</a>
<a name="36"><span class="lineNum">      36 </span>                :            : </a>
<a name="37"><span class="lineNum">      37 </span>                :            :     static constexpr char_type* move(char_type* s1, const char_type* s2, size_t n); // constexpr in C++20</a>
<a name="38"><span class="lineNum">      38 </span>                :            :     static constexpr char_type* copy(char_type* s1, const char_type* s2, size_t n); // constexpr in C++20</a>
<a name="39"><span class="lineNum">      39 </span>                :            :     static constexpr char_type* assign(char_type* s, size_t n, char_type a);        // constexpr in C++20</a>
<a name="40"><span class="lineNum">      40 </span>                :            : </a>
<a name="41"><span class="lineNum">      41 </span>                :            :     static constexpr int_type  not_eof(int_type c) noexcept;</a>
<a name="42"><span class="lineNum">      42 </span>                :            :     static constexpr char_type to_char_type(int_type c) noexcept;</a>
<a name="43"><span class="lineNum">      43 </span>                :            :     static constexpr int_type  to_int_type(char_type c) noexcept;</a>
<a name="44"><span class="lineNum">      44 </span>                :            :     static constexpr bool      eq_int_type(int_type c1, int_type c2) noexcept;</a>
<a name="45"><span class="lineNum">      45 </span>                :            :     static constexpr int_type  eof() noexcept;</a>
<a name="46"><span class="lineNum">      46 </span>                :            : };</a>
<a name="47"><span class="lineNum">      47 </span>                :            : </a>
<a name="48"><span class="lineNum">      48 </span>                :            : template &lt;&gt; struct char_traits&lt;char&gt;;</a>
<a name="49"><span class="lineNum">      49 </span>                :            : template &lt;&gt; struct char_traits&lt;wchar_t&gt;;</a>
<a name="50"><span class="lineNum">      50 </span>                :            : template &lt;&gt; struct char_traits&lt;char8_t&gt;;  // c++20</a>
<a name="51"><span class="lineNum">      51 </span>                :            : </a>
<a name="52"><span class="lineNum">      52 </span>                :            : }  // std</a>
<a name="53"><span class="lineNum">      53 </span>                :            : </a>
<a name="54"><span class="lineNum">      54 </span>                :            : */</a>
<a name="55"><span class="lineNum">      55 </span>                :            : </a>
<a name="56"><span class="lineNum">      56 </span>                :            : #include &lt;__config&gt;</a>
<a name="57"><span class="lineNum">      57 </span>                :            : #include &lt;algorithm&gt;  // for search and min</a>
<a name="58"><span class="lineNum">      58 </span>                :            : #include &lt;cstdio&gt;     // for EOF</a>
<a name="59"><span class="lineNum">      59 </span>                :            : #include &lt;cstring&gt;    // for memcpy</a>
<a name="60"><span class="lineNum">      60 </span>                :            : #include &lt;cwchar&gt;     // for wmemcpy</a>
<a name="61"><span class="lineNum">      61 </span>                :            : #include &lt;memory&gt;     // for __murmur2_or_cityhash</a>
<a name="62"><span class="lineNum">      62 </span>                :            : </a>
<a name="63"><span class="lineNum">      63 </span>                :            : #include &lt;__debug&gt;</a>
<a name="64"><span class="lineNum">      64 </span>                :            : </a>
<a name="65"><span class="lineNum">      65 </span>                :            : #if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)</a>
<a name="66"><span class="lineNum">      66 </span>                :            : #pragma GCC system_header</a>
<a name="67"><span class="lineNum">      67 </span>                :            : #endif</a>
<a name="68"><span class="lineNum">      68 </span>                :            : </a>
<a name="69"><span class="lineNum">      69 </span>                :            : _LIBCPP_PUSH_MACROS</a>
<a name="70"><span class="lineNum">      70 </span>                :            : #include &lt;__undef_macros&gt;</a>
<a name="71"><span class="lineNum">      71 </span>                :            : </a>
<a name="72"><span class="lineNum">      72 </span>                :            : </a>
<a name="73"><span class="lineNum">      73 </span>                :            : _LIBCPP_BEGIN_NAMESPACE_STD</a>
<a name="74"><span class="lineNum">      74 </span>                :            : </a>
<a name="75"><span class="lineNum">      75 </span>                :            : // The the extern template ABI lists are kept outside of &lt;string&gt; to improve the</a>
<a name="76"><span class="lineNum">      76 </span>                :            : // readability of that header.</a>
<a name="77"><span class="lineNum">      77 </span>                :            : </a>
<a name="78"><span class="lineNum">      78 </span>                :            : // The extern template ABI lists are kept outside of &lt;string&gt; to improve the</a>
<a name="79"><span class="lineNum">      79 </span>                :            : // readability of that header. We maintain 2 ABI lists:</a>
<a name="80"><span class="lineNum">      80 </span>                :            : // - _LIBCPP_STRING_V1_EXTERN_TEMPLATE_LIST</a>
<a name="81"><span class="lineNum">      81 </span>                :            : // - _LIBCPP_STRING_UNSTABLE_EXTERN_TEMPLATE_LIST</a>
<a name="82"><span class="lineNum">      82 </span>                :            : // As the name implies, the ABI lists define the V1 (Stable) and unstable ABI.</a>
<a name="83"><span class="lineNum">      83 </span>                :            : //</a>
<a name="84"><span class="lineNum">      84 </span>                :            : // For unstable, we may explicitly remove function that are external in V1,</a>
<a name="85"><span class="lineNum">      85 </span>                :            : // and add (new) external functions to better control inlining and compiler</a>
<a name="86"><span class="lineNum">      86 </span>                :            : // optimization opportunities.</a>
<a name="87"><span class="lineNum">      87 </span>                :            : //</a>
<a name="88"><span class="lineNum">      88 </span>                :            : // For stable, the ABI list should rarely change, except for adding new</a>
<a name="89"><span class="lineNum">      89 </span>                :            : // functions supporting new c++ version / API changes. Typically entries</a>
<a name="90"><span class="lineNum">      90 </span>                :            : // must never be removed from the stable list.</a>
<a name="91"><span class="lineNum">      91 </span>                :            : #define _LIBCPP_STRING_V1_EXTERN_TEMPLATE_LIST(_Func, _CharType) \</a>
<a name="92"><span class="lineNum">      92 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, value_type const*, size_type)) \</a>
<a name="93"><span class="lineNum">      93 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::rfind(value_type const*, size_type, size_type) const) \</a>
<a name="94"><span class="lineNum">      94 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(value_type const*, size_type, size_type)) \</a>
<a name="95"><span class="lineNum">      95 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::basic_string(basic_string const&amp;)) \</a>
<a name="96"><span class="lineNum">      96 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, value_type const*)) \</a>
<a name="97"><span class="lineNum">      97 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::basic_string(basic_string const&amp;, allocator&lt;_CharType&gt; const&amp;)) \</a>
<a name="98"><span class="lineNum">      98 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_last_not_of(value_type const*, size_type, size_type) const) \</a>
<a name="99"><span class="lineNum">      99 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::~basic_string()) \</a>
<a name="100"><span class="lineNum">     100 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_first_not_of(value_type const*, size_type, size_type) const) \</a>
<a name="101"><span class="lineNum">     101 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, size_type, value_type)) \</a>
<a name="102"><span class="lineNum">     102 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::operator=(value_type)) \</a>
<a name="103"><span class="lineNum">     103 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(value_type const*, size_type)) \</a>
<a name="104"><span class="lineNum">     104 </span>                :            :   _Func(_LIBCPP_FUNC_VIS const _CharType&amp; basic_string&lt;_CharType&gt;::at(size_type) const) \</a>
<a name="105"><span class="lineNum">     105 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, value_type const*, size_type)) \</a>
<a name="106"><span class="lineNum">     106 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_first_of(value_type const*, size_type, size_type) const) \</a>
<a name="107"><span class="lineNum">     107 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, size_type, value_type)) \</a>
<a name="108"><span class="lineNum">     108 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(value_type const*, size_type)) \</a>
<a name="109"><span class="lineNum">     109 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::reserve(size_type)) \</a>
<a name="110"><span class="lineNum">     110 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(value_type const*, size_type)) \</a>
<a name="111"><span class="lineNum">     111 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(basic_string const&amp;, size_type, size_type)) \</a>
<a name="112"><span class="lineNum">     112 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::copy(value_type*, size_type, size_type) const) \</a>
<a name="113"><span class="lineNum">     113 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::basic_string(basic_string const&amp;, size_type, size_type, allocator&lt;_CharType&gt; const&amp;)) \</a>
<a name="114"><span class="lineNum">     114 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find(value_type, size_type) const) \</a>
<a name="115"><span class="lineNum">     115 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(size_type, value_type)) \</a>
<a name="116"><span class="lineNum">     116 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, value_type const*)) \</a>
<a name="117"><span class="lineNum">     117 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_last_of(value_type const*, size_type, size_type) const) \</a>
<a name="118"><span class="lineNum">     118 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__grow_by(size_type, size_type, size_type, size_type, size_type, size_type)) \</a>
<a name="119"><span class="lineNum">     119 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__grow_by_and_replace(size_type, size_type, size_type, size_type, size_type, size_type, value_type const*)) \</a>
<a name="120"><span class="lineNum">     120 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::push_back(value_type)) \</a>
<a name="121"><span class="lineNum">     121 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(size_type, value_type)) \</a>
<a name="122"><span class="lineNum">     122 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::rfind(value_type, size_type) const) \</a>
<a name="123"><span class="lineNum">     123 </span>                :            :   _Func(_LIBCPP_FUNC_VIS const basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::npos) \</a>
<a name="124"><span class="lineNum">     124 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(size_type, value_type)) \</a>
<a name="125"><span class="lineNum">     125 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::erase(size_type, size_type)) \</a>
<a name="126"><span class="lineNum">     126 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(basic_string const&amp;, size_type, size_type)) \</a>
<a name="127"><span class="lineNum">     127 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(value_type const*) const) \</a>
<a name="128"><span class="lineNum">     128 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, value_type const*) const) \</a>
<a name="129"><span class="lineNum">     129 </span>                :            :   _Func(_LIBCPP_FUNC_VIS _CharType&amp; basic_string&lt;_CharType&gt;::at(size_type)) \</a>
<a name="130"><span class="lineNum">     130 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(value_type const*)) \</a>
<a name="131"><span class="lineNum">     131 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find(value_type const*, size_type, size_type) const) \</a>
<a name="132"><span class="lineNum">     132 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, basic_string const&amp;, size_type, size_type) const) \</a>
<a name="133"><span class="lineNum">     133 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, value_type const*, size_type) const) \</a>
<a name="134"><span class="lineNum">     134 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::operator=(basic_string const&amp;)) \</a>
<a name="135"><span class="lineNum">     135 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(value_type const*)) \</a>
<a name="136"><span class="lineNum">     136 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, basic_string const&amp;, size_type, size_type)) \</a>
<a name="137"><span class="lineNum">     137 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::iterator basic_string&lt;_CharType&gt;::insert(basic_string::const_iterator, value_type)) \</a>
<a name="138"><span class="lineNum">     138 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::resize(size_type, value_type)) \</a>
<a name="139"><span class="lineNum">     139 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, basic_string const&amp;, size_type, size_type))</a>
<a name="140"><span class="lineNum">     140 </span>                :            : </a>
<a name="141"><span class="lineNum">     141 </span>                :            : #define _LIBCPP_STRING_UNSTABLE_EXTERN_TEMPLATE_LIST(_Func, _CharType) \</a>
<a name="142"><span class="lineNum">     142 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, value_type const*, size_type)) \</a>
<a name="143"><span class="lineNum">     143 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::rfind(value_type const*, size_type, size_type) const) \</a>
<a name="144"><span class="lineNum">     144 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(value_type const*, size_type, size_type)) \</a>
<a name="145"><span class="lineNum">     145 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, value_type const*)) \</a>
<a name="146"><span class="lineNum">     146 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_last_not_of(value_type const*, size_type, size_type) const) \</a>
<a name="147"><span class="lineNum">     147 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::~basic_string()) \</a>
<a name="148"><span class="lineNum">     148 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_first_not_of(value_type const*, size_type, size_type) const) \</a>
<a name="149"><span class="lineNum">     149 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, size_type, value_type)) \</a>
<a name="150"><span class="lineNum">     150 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::operator=(value_type)) \</a>
<a name="151"><span class="lineNum">     151 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(value_type const*, size_type)) \</a>
<a name="152"><span class="lineNum">     152 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init_copy_ctor_external(value_type const*, size_type)) \</a>
<a name="153"><span class="lineNum">     153 </span>                :            :   _Func(_LIBCPP_FUNC_VIS const _CharType&amp; basic_string&lt;_CharType&gt;::at(size_type) const) \</a>
<a name="154"><span class="lineNum">     154 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, value_type const*, size_type)) \</a>
<a name="155"><span class="lineNum">     155 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_first_of(value_type const*, size_type, size_type) const) \</a>
<a name="156"><span class="lineNum">     156 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, size_type, value_type)) \</a>
<a name="157"><span class="lineNum">     157 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::__assign_external(value_type const*, size_type)) \</a>
<a name="158"><span class="lineNum">     158 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::__assign_external(value_type const*)) \</a>
<a name="159"><span class="lineNum">     159 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::reserve(size_type)) \</a>
<a name="160"><span class="lineNum">     160 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(value_type const*, size_type)) \</a>
<a name="161"><span class="lineNum">     161 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(basic_string const&amp;, size_type, size_type)) \</a>
<a name="162"><span class="lineNum">     162 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::copy(value_type*, size_type, size_type) const) \</a>
<a name="163"><span class="lineNum">     163 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::basic_string(basic_string const&amp;, size_type, size_type, allocator&lt;_CharType&gt; const&amp;)) \</a>
<a name="164"><span class="lineNum">     164 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find(value_type, size_type) const) \</a>
<a name="165"><span class="lineNum">     165 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__init(size_type, value_type)) \</a>
<a name="166"><span class="lineNum">     166 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, value_type const*)) \</a>
<a name="167"><span class="lineNum">     167 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find_last_of(value_type const*, size_type, size_type) const) \</a>
<a name="168"><span class="lineNum">     168 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__grow_by(size_type, size_type, size_type, size_type, size_type, size_type)) \</a>
<a name="169"><span class="lineNum">     169 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__grow_by_and_replace(size_type, size_type, size_type, size_type, size_type, size_type, value_type const*)) \</a>
<a name="170"><span class="lineNum">     170 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::__assign_no_alias&lt;false&gt;(value_type const*, size_type)) \</a>
<a name="171"><span class="lineNum">     171 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::__assign_no_alias&lt;true&gt;(value_type const*, size_type)) \</a>
<a name="172"><span class="lineNum">     172 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::push_back(value_type)) \</a>
<a name="173"><span class="lineNum">     173 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(size_type, value_type)) \</a>
<a name="174"><span class="lineNum">     174 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::rfind(value_type, size_type) const) \</a>
<a name="175"><span class="lineNum">     175 </span>                :            :   _Func(_LIBCPP_FUNC_VIS const basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::npos) \</a>
<a name="176"><span class="lineNum">     176 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::assign(size_type, value_type)) \</a>
<a name="177"><span class="lineNum">     177 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::__erase_external_with_move(size_type, size_type)) \</a>
<a name="178"><span class="lineNum">     178 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(basic_string const&amp;, size_type, size_type)) \</a>
<a name="179"><span class="lineNum">     179 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(value_type const*) const) \</a>
<a name="180"><span class="lineNum">     180 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, value_type const*) const) \</a>
<a name="181"><span class="lineNum">     181 </span>                :            :   _Func(_LIBCPP_FUNC_VIS _CharType&amp; basic_string&lt;_CharType&gt;::at(size_type)) \</a>
<a name="182"><span class="lineNum">     182 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::size_type basic_string&lt;_CharType&gt;::find(value_type const*, size_type, size_type) const) \</a>
<a name="183"><span class="lineNum">     183 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, basic_string const&amp;, size_type, size_type) const) \</a>
<a name="184"><span class="lineNum">     184 </span>                :            :   _Func(_LIBCPP_FUNC_VIS int basic_string&lt;_CharType&gt;::compare(size_type, size_type, value_type const*, size_type) const) \</a>
<a name="185"><span class="lineNum">     185 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::append(value_type const*)) \</a>
<a name="186"><span class="lineNum">     186 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::replace(size_type, size_type, basic_string const&amp;, size_type, size_type)) \</a>
<a name="187"><span class="lineNum">     187 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;::iterator basic_string&lt;_CharType&gt;::insert(basic_string::const_iterator, value_type)) \</a>
<a name="188"><span class="lineNum">     188 </span>                :            :   _Func(_LIBCPP_FUNC_VIS void basic_string&lt;_CharType&gt;::resize(size_type, value_type)) \</a>
<a name="189"><span class="lineNum">     189 </span>                :            :   _Func(_LIBCPP_FUNC_VIS basic_string&lt;_CharType&gt;&amp; basic_string&lt;_CharType&gt;::insert(size_type, basic_string const&amp;, size_type, size_type))</a>
<a name="190"><span class="lineNum">     190 </span>                :            : </a>
<a name="191"><span class="lineNum">     191 </span>                :            : </a>
<a name="192"><span class="lineNum">     192 </span>                :            : // char_traits</a>
<a name="193"><span class="lineNum">     193 </span>                :            : </a>
<a name="194"><span class="lineNum">     194 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="195"><span class="lineNum">     195 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits</a>
<a name="196"><span class="lineNum">     196 </span>                :            : {</a>
<a name="197"><span class="lineNum">     197 </span>                :            :     typedef _CharT    char_type;</a>
<a name="198"><span class="lineNum">     198 </span>                :            :     typedef int       int_type;</a>
<a name="199"><span class="lineNum">     199 </span>                :            :     typedef streamoff off_type;</a>
<a name="200"><span class="lineNum">     200 </span>                :            :     typedef streampos pos_type;</a>
<a name="201"><span class="lineNum">     201 </span>                :            :     typedef mbstate_t state_type;</a>
<a name="202"><span class="lineNum">     202 </span>                :            : </a>
<a name="203"><span class="lineNum">     203 </span>                :            :     static inline void _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="204"><span class="lineNum">     204 </span>                :            :         assign(char_type&amp; __c1, const char_type&amp; __c2) _NOEXCEPT {__c1 = __c2;}</a>
<a name="205"><span class="lineNum">     205 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="206"><span class="lineNum">     206 </span>                :            :         {return __c1 == __c2;}</a>
<a name="207"><span class="lineNum">     207 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="208"><span class="lineNum">     208 </span>                :            :         {return __c1 &lt; __c2;}</a>
<a name="209"><span class="lineNum">     209 </span>                :            : </a>
<a name="210"><span class="lineNum">     210 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="211"><span class="lineNum">     211 </span>                :            :     int compare(const char_type* __s1, const char_type* __s2, size_t __n);</a>
<a name="212"><span class="lineNum">     212 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="213"><span class="lineNum">     213 </span>                :            :     size_t length(const char_type* __s);</a>
<a name="214"><span class="lineNum">     214 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="215"><span class="lineNum">     215 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a);</a>
<a name="216"><span class="lineNum">     216 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="217"><span class="lineNum">     217 </span>                :            :     char_type*       move(char_type* __s1, const char_type* __s2, size_t __n);</a>
<a name="218"><span class="lineNum">     218 </span>                :            :     _LIBCPP_INLINE_VISIBILITY</a>
<a name="219"><span class="lineNum">     219 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="220"><span class="lineNum">     220 </span>                :            :     char_type*       copy(char_type* __s1, const char_type* __s2, size_t __n);</a>
<a name="221"><span class="lineNum">     221 </span>                :            :     _LIBCPP_INLINE_VISIBILITY</a>
<a name="222"><span class="lineNum">     222 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="223"><span class="lineNum">     223 </span>                :            :     char_type*       assign(char_type* __s, size_t __n, char_type __a);</a>
<a name="224"><span class="lineNum">     224 </span>                :            : </a>
<a name="225"><span class="lineNum">     225 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT</a>
<a name="226"><span class="lineNum">     226 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="227"><span class="lineNum">     227 </span>                :            :     static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT</a>
<a name="228"><span class="lineNum">     228 </span>                :            :         {return char_type(__c);}</a>
<a name="229"><span class="lineNum">     229 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  to_int_type(char_type __c) _NOEXCEPT</a>
<a name="230"><span class="lineNum">     230 </span>                :            :         {return int_type(__c);}</a>
<a name="231"><span class="lineNum">     231 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool      eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT</a>
<a name="232"><span class="lineNum">     232 </span>                :            :         {return __c1 == __c2;}</a>
<a name="233"><span class="lineNum">     233 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT</a>
<a name="234"><span class="lineNum">     234 </span>                :            :         {return int_type(EOF);}</a>
<a name="235"><span class="lineNum">     235 </span>                :            : };</a>
<a name="236"><span class="lineNum">     236 </span>                :            : </a>
<a name="237"><span class="lineNum">     237 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="238"><span class="lineNum">     238 </span>                :            : _LIBCPP_CONSTEXPR_AFTER_CXX14 int</a>
<a name="239"><span class="lineNum">     239 </span>                :            : char_traits&lt;_CharT&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n)</a>
<a name="240"><span class="lineNum">     240 </span>                :            : {</a>
<a name="241"><span class="lineNum">     241 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="242"><span class="lineNum">     242 </span>                :            :     {</a>
<a name="243"><span class="lineNum">     243 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="244"><span class="lineNum">     244 </span>                :            :             return -1;</a>
<a name="245"><span class="lineNum">     245 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="246"><span class="lineNum">     246 </span>                :            :             return 1;</a>
<a name="247"><span class="lineNum">     247 </span>                :            :     }</a>
<a name="248"><span class="lineNum">     248 </span>                :            :     return 0;</a>
<a name="249"><span class="lineNum">     249 </span>                :            : }</a>
<a name="250"><span class="lineNum">     250 </span>                :            : </a>
<a name="251"><span class="lineNum">     251 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="252"><span class="lineNum">     252 </span>                :            : inline</a>
<a name="253"><span class="lineNum">     253 </span>                :            : _LIBCPP_CONSTEXPR_AFTER_CXX14 size_t</a>
<a name="254"><span class="lineNum">     254 </span>                :            : char_traits&lt;_CharT&gt;::length(const char_type* __s)</a>
<a name="255"><span class="lineNum">     255 </span>                :            : {</a>
<a name="256"><span class="lineNum">     256 </span>                :            :     size_t __len = 0;</a>
<a name="257"><span class="lineNum">     257 </span>                :            :     for (; !eq(*__s, char_type(0)); ++__s)</a>
<a name="258"><span class="lineNum">     258 </span>                :            :         ++__len;</a>
<a name="259"><span class="lineNum">     259 </span>                :            :     return __len;</a>
<a name="260"><span class="lineNum">     260 </span>                :            : }</a>
<a name="261"><span class="lineNum">     261 </span>                :            : </a>
<a name="262"><span class="lineNum">     262 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="263"><span class="lineNum">     263 </span>                :            : inline</a>
<a name="264"><span class="lineNum">     264 </span>                :            : _LIBCPP_CONSTEXPR_AFTER_CXX14 const _CharT*</a>
<a name="265"><span class="lineNum">     265 </span>                :            : char_traits&lt;_CharT&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a)</a>
<a name="266"><span class="lineNum">     266 </span>                :            : {</a>
<a name="267"><span class="lineNum">     267 </span>                :            :     for (; __n; --__n)</a>
<a name="268"><span class="lineNum">     268 </span>                :            :     {</a>
<a name="269"><span class="lineNum">     269 </span>                :            :         if (eq(*__s, __a))</a>
<a name="270"><span class="lineNum">     270 </span>                :            :             return __s;</a>
<a name="271"><span class="lineNum">     271 </span>                :            :         ++__s;</a>
<a name="272"><span class="lineNum">     272 </span>                :            :     }</a>
<a name="273"><span class="lineNum">     273 </span>                :            :     return nullptr;</a>
<a name="274"><span class="lineNum">     274 </span>                :            : }</a>
<a name="275"><span class="lineNum">     275 </span>                :            : </a>
<a name="276"><span class="lineNum">     276 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="277"><span class="lineNum">     277 </span>                :            : _LIBCPP_CONSTEXPR_AFTER_CXX17 _CharT*</a>
<a name="278"><span class="lineNum">     278 </span>                :            : char_traits&lt;_CharT&gt;::move(char_type* __s1, const char_type* __s2, size_t __n)</a>
<a name="279"><span class="lineNum">     279 </span>                :            : {</a>
<a name="280"><span class="lineNum">     280 </span>                :            :     if (__n == 0) return __s1;</a>
<a name="281"><span class="lineNum">     281 </span>                :            :     char_type* __r = __s1;</a>
<a name="282"><span class="lineNum">     282 </span>                :            :     if (__s1 &lt; __s2)</a>
<a name="283"><span class="lineNum">     283 </span>                :            :     {</a>
<a name="284"><span class="lineNum">     284 </span>                :            :         for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="285"><span class="lineNum">     285 </span>                :            :             assign(*__s1, *__s2);</a>
<a name="286"><span class="lineNum">     286 </span>                :            :     }</a>
<a name="287"><span class="lineNum">     287 </span>                :            :     else if (__s2 &lt; __s1)</a>
<a name="288"><span class="lineNum">     288 </span>                :            :     {</a>
<a name="289"><span class="lineNum">     289 </span>                :            :         __s1 += __n;</a>
<a name="290"><span class="lineNum">     290 </span>                :            :         __s2 += __n;</a>
<a name="291"><span class="lineNum">     291 </span>                :            :         for (; __n; --__n)</a>
<a name="292"><span class="lineNum">     292 </span>                :            :             assign(*--__s1, *--__s2);</a>
<a name="293"><span class="lineNum">     293 </span>                :            :     }</a>
<a name="294"><span class="lineNum">     294 </span>                :            :     return __r;</a>
<a name="295"><span class="lineNum">     295 </span>                :            : }</a>
<a name="296"><span class="lineNum">     296 </span>                :            : </a>
<a name="297"><span class="lineNum">     297 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="298"><span class="lineNum">     298 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="299"><span class="lineNum">     299 </span>                :            : _CharT*</a>
<a name="300"><span class="lineNum">     300 </span>                :            : char_traits&lt;_CharT&gt;::copy(char_type* __s1, const char_type* __s2, size_t __n)</a>
<a name="301"><span class="lineNum">     301 </span>                :            : {</a>
<a name="302"><span class="lineNum">     302 </span>                :            :     _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="303"><span class="lineNum">     303 </span>                :            :     char_type* __r = __s1;</a>
<a name="304"><span class="lineNum">     304 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="305"><span class="lineNum">     305 </span>                :            :         assign(*__s1, *__s2);</a>
<a name="306"><span class="lineNum">     306 </span>                :            :     return __r;</a>
<a name="307"><span class="lineNum">     307 </span>                :            : }</a>
<a name="308"><span class="lineNum">     308 </span>                :            : </a>
<a name="309"><span class="lineNum">     309 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="310"><span class="lineNum">     310 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="311"><span class="lineNum">     311 </span>                :            : _CharT*</a>
<a name="312"><span class="lineNum">     312 </span>                :            : char_traits&lt;_CharT&gt;::assign(char_type* __s, size_t __n, char_type __a)</a>
<a name="313"><span class="lineNum">     313 </span>                :            : {</a>
<a name="314"><span class="lineNum">     314 </span>                :            :     char_type* __r = __s;</a>
<a name="315"><span class="lineNum">     315 </span>                :            :     for (; __n; --__n, ++__s)</a>
<a name="316"><span class="lineNum">     316 </span>                :            :         assign(*__s, __a);</a>
<a name="317"><span class="lineNum">     317 </span>                :            :     return __r;</a>
<a name="318"><span class="lineNum">     318 </span>                :            : }</a>
<a name="319"><span class="lineNum">     319 </span>                :            : </a>
<a name="320"><span class="lineNum">     320 </span>                :            : // constexpr versions of move/copy/assign.</a>
<a name="321"><span class="lineNum">     321 </span>                :            : </a>
<a name="322"><span class="lineNum">     322 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="323"><span class="lineNum">     323 </span>                :            : static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="324"><span class="lineNum">     324 </span>                :            : _CharT* __move_constexpr(_CharT* __s1, const _CharT* __s2, size_t __n) _NOEXCEPT</a>
<a name="325"><span class="lineNum">     325 </span>                :            : {</a>
<a name="326"><span class="lineNum">     326 </span>                :            :     if (__n == 0) return __s1;</a>
<a name="327"><span class="lineNum">     327 </span>                :            :     if (__s1 &lt; __s2) {</a>
<a name="328"><span class="lineNum">     328 </span>                :            :       _VSTD::copy(__s2, __s2 + __n, __s1);</a>
<a name="329"><span class="lineNum">     329 </span>                :            :     } else if (__s2 &lt; __s1) {</a>
<a name="330"><span class="lineNum">     330 </span>                :            :       _VSTD::copy_backward(__s2, __s2 + __n, __s1 + __n);</a>
<a name="331"><span class="lineNum">     331 </span>                :            :     }</a>
<a name="332"><span class="lineNum">     332 </span>                :            :     return __s1;</a>
<a name="333"><span class="lineNum">     333 </span>                :            : }</a>
<a name="334"><span class="lineNum">     334 </span>                :            : </a>
<a name="335"><span class="lineNum">     335 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="336"><span class="lineNum">     336 </span>                :            : static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="337"><span class="lineNum">     337 </span>                :            : _CharT* __copy_constexpr(_CharT* __s1, const _CharT* __s2, size_t __n) _NOEXCEPT</a>
<a name="338"><span class="lineNum">     338 </span>                :            : {</a>
<a name="339"><span class="lineNum">     339 </span>                :            :     _VSTD::copy_n(__s2, __n, __s1);</a>
<a name="340"><span class="lineNum">     340 </span>                :            :     return __s1;</a>
<a name="341"><span class="lineNum">     341 </span>                :            : }</a>
<a name="342"><span class="lineNum">     342 </span>                :            : </a>
<a name="343"><span class="lineNum">     343 </span>                :            : template &lt;class _CharT&gt;</a>
<a name="344"><span class="lineNum">     344 </span>                :            : static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="345"><span class="lineNum">     345 </span>                :            : _CharT* __assign_constexpr(_CharT* __s, size_t __n, _CharT __a) _NOEXCEPT</a>
<a name="346"><span class="lineNum">     346 </span>                :            : {</a>
<a name="347"><span class="lineNum">     347 </span>                :            :      _VSTD::fill_n(__s, __n, __a);</a>
<a name="348"><span class="lineNum">     348 </span>                :            :      return __s;</a>
<a name="349"><span class="lineNum">     349 </span>                :            : }</a>
<a name="350"><span class="lineNum">     350 </span>                :            : </a>
<a name="351"><span class="lineNum">     351 </span>                :            : // char_traits&lt;char&gt;</a>
<a name="352"><span class="lineNum">     352 </span>                :            : </a>
<a name="353"><span class="lineNum">     353 </span>                :            : template &lt;&gt;</a>
<a name="354"><span class="lineNum">     354 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits&lt;char&gt;</a>
<a name="355"><span class="lineNum">     355 </span>                :            : {</a>
<a name="356"><span class="lineNum">     356 </span>                :            :     typedef char      char_type;</a>
<a name="357"><span class="lineNum">     357 </span>                :            :     typedef int       int_type;</a>
<a name="358"><span class="lineNum">     358 </span>                :            :     typedef streamoff off_type;</a>
<a name="359"><span class="lineNum">     359 </span>                :            :     typedef streampos pos_type;</a>
<a name="360"><span class="lineNum">     360 </span>                :            :     typedef mbstate_t state_type;</a>
<a name="361"><span class="lineNum">     361 </span>                :            : </a>
<a name="362"><span class="lineNum">     362 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="363"><span class="lineNum">     363 </span>                :<span class="lineNoCov">          0 :     void assign(char_type&amp; __c1, const char_type&amp; __c2) _NOEXCEPT {__c1 = __c2;}</span></a>
<a name="364"><span class="lineNum">     364 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="365"><span class="lineNum">     365 </span>                :            :             {return __c1 == __c2;}</a>
<a name="366"><span class="lineNum">     366 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="367"><span class="lineNum">     367 </span>                :            :         {return (unsigned char)__c1 &lt; (unsigned char)__c2;}</a>
<a name="368"><span class="lineNum">     368 </span>                :            : </a>
<a name="369"><span class="lineNum">     369 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="370"><span class="lineNum">     370 </span>                :            :     int compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="371"><span class="lineNum">     371 </span>                :            :     static inline size_t _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="372"><span class="lineNum">     372 </span>                :<span class="lineCov">          3 :     length(const char_type* __s)  _NOEXCEPT {return __builtin_strlen(__s);}</span></a>
<a name="373"><span class="lineNum">     373 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="374"><span class="lineNum">     374 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT;</a>
<a name="375"><span class="lineNum">     375 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="376"><span class="lineNum">     376 </span>                :            :     char_type* move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="377"><span class="lineNum">     377 </span>                :            :         {</a>
<a name="378"><span class="lineNum">     378 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="379"><span class="lineNum">     379 </span>                :            :                        ? _VSTD::__move_constexpr(__s1, __s2, __n)</a>
<a name="380"><span class="lineNum">     380 </span>                :            :                        : __n == 0 ? __s1 : (char_type*)_VSTD::memmove(__s1, __s2, __n);</a>
<a name="381"><span class="lineNum">     381 </span>                :            :         }</a>
<a name="382"><span class="lineNum">     382 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="383"><span class="lineNum">     383 </span>                :<span class="lineNoCov">          0 :     char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</span></a>
<a name="384"><span class="lineNum">     384 </span>                :            :         {</a>
<a name="385"><span class="lineNum">     385 </span>                :            :             _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="386"><span class="lineNum">     386 </span>                :<span class="lineNoCov">          0 :             return __libcpp_is_constant_evaluated()</span></a>
<a name="387"><span class="lineNum">     387 </span>                :            :                        ? _VSTD::__copy_constexpr(__s1, __s2, __n)</a>
<a name="388"><span class="lineNum">     388 </span>                :<span class="lineNoCov">          0 :                        : __n == 0 ? __s1 : (char_type*)_VSTD::memcpy(__s1, __s2, __n);</span></a>
<a name="389"><span class="lineNum">     389 </span>                :            :         }</a>
<a name="390"><span class="lineNum">     390 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="391"><span class="lineNum">     391 </span>                :            :     char_type* assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT</a>
<a name="392"><span class="lineNum">     392 </span>                :            :         {</a>
<a name="393"><span class="lineNum">     393 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="394"><span class="lineNum">     394 </span>                :            :                        ? _VSTD::__assign_constexpr(__s, __n, __a)</a>
<a name="395"><span class="lineNum">     395 </span>                :            :                        : __n == 0 ? __s : (char_type*)_VSTD::memset(__s, to_int_type(__a), __n);</a>
<a name="396"><span class="lineNum">     396 </span>                :            :         }</a>
<a name="397"><span class="lineNum">     397 </span>                :            : </a>
<a name="398"><span class="lineNum">     398 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT</a>
<a name="399"><span class="lineNum">     399 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="400"><span class="lineNum">     400 </span>                :            :     static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT</a>
<a name="401"><span class="lineNum">     401 </span>                :            :         {return char_type(__c);}</a>
<a name="402"><span class="lineNum">     402 </span>                :<span class="lineCov">         27 :     static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT</span></a>
<a name="403"><span class="lineNum">     403 </span>                :<span class="lineCov">         27 :         {return int_type((unsigned char)__c);}</span></a>
<a name="404"><span class="lineNum">     404 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT</a>
<a name="405"><span class="lineNum">     405 </span>                :            :         {return __c1 == __c2;}</a>
<a name="406"><span class="lineNum">     406 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  eof() _NOEXCEPT</a>
<a name="407"><span class="lineNum">     407 </span>                :            :         {return int_type(EOF);}</a>
<a name="408"><span class="lineNum">     408 </span>                :            : };</a>
<a name="409"><span class="lineNum">     409 </span>                :            : </a>
<a name="410"><span class="lineNum">     410 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="411"><span class="lineNum">     411 </span>                :            : int</a>
<a name="412"><span class="lineNum">     412 </span>                :            : char_traits&lt;char&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="413"><span class="lineNum">     413 </span>                :            : {</a>
<a name="414"><span class="lineNum">     414 </span>                :            :     if (__n == 0)</a>
<a name="415"><span class="lineNum">     415 </span>                :            :         return 0;</a>
<a name="416"><span class="lineNum">     416 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="417"><span class="lineNum">     417 </span>                :            :     return __builtin_memcmp(__s1, __s2, __n);</a>
<a name="418"><span class="lineNum">     418 </span>                :            : #elif _LIBCPP_STD_VER &lt;= 14</a>
<a name="419"><span class="lineNum">     419 </span>                :            :     return _VSTD::memcmp(__s1, __s2, __n);</a>
<a name="420"><span class="lineNum">     420 </span>                :            : #else</a>
<a name="421"><span class="lineNum">     421 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="422"><span class="lineNum">     422 </span>                :            :     {</a>
<a name="423"><span class="lineNum">     423 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="424"><span class="lineNum">     424 </span>                :            :             return -1;</a>
<a name="425"><span class="lineNum">     425 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="426"><span class="lineNum">     426 </span>                :            :             return 1;</a>
<a name="427"><span class="lineNum">     427 </span>                :            :     }</a>
<a name="428"><span class="lineNum">     428 </span>                :            :     return 0;</a>
<a name="429"><span class="lineNum">     429 </span>                :            : #endif</a>
<a name="430"><span class="lineNum">     430 </span>                :            : }</a>
<a name="431"><span class="lineNum">     431 </span>                :            : </a>
<a name="432"><span class="lineNum">     432 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="433"><span class="lineNum">     433 </span>                :            : const char*</a>
<a name="434"><span class="lineNum">     434 </span>                :<span class="lineCov">         27 : char_traits&lt;char&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT</span></a>
<a name="435"><span class="lineNum">     435 </span>                :            : {</a>
<a name="436"><span class="lineNum">     436 </span>                :<span class="lineCov">         27 :     if (__n == 0)</span></a>
<a name="437"><span class="lineNum">     437 </span>                :<span class="lineNoCov">          0 :         return nullptr;</span></a>
<a name="438"><span class="lineNum">     438 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="439"><span class="lineNum">     439 </span>                :<span class="lineCov">         27 :     return __builtin_char_memchr(__s, to_int_type(__a), __n);</span></a>
<a name="440"><span class="lineNum">     440 </span>                :            : #elif _LIBCPP_STD_VER &lt;= 14</a>
<a name="441"><span class="lineNum">     441 </span>                :            :     return (const char_type*) _VSTD::memchr(__s, to_int_type(__a), __n);</a>
<a name="442"><span class="lineNum">     442 </span>                :            : #else</a>
<a name="443"><span class="lineNum">     443 </span>                :            :     for (; __n; --__n)</a>
<a name="444"><span class="lineNum">     444 </span>                :            :     {</a>
<a name="445"><span class="lineNum">     445 </span>                :            :         if (eq(*__s, __a))</a>
<a name="446"><span class="lineNum">     446 </span>                :            :             return __s;</a>
<a name="447"><span class="lineNum">     447 </span>                :            :         ++__s;</a>
<a name="448"><span class="lineNum">     448 </span>                :            :     }</a>
<a name="449"><span class="lineNum">     449 </span>                :            :     return nullptr;</a>
<a name="450"><span class="lineNum">     450 </span>                :            : #endif</a>
<a name="451"><span class="lineNum">     451 </span>                :<span class="lineCov">         27 : }</span></a>
<a name="452"><span class="lineNum">     452 </span>                :            : </a>
<a name="453"><span class="lineNum">     453 </span>                :            : </a>
<a name="454"><span class="lineNum">     454 </span>                :            : // char_traits&lt;wchar_t&gt;</a>
<a name="455"><span class="lineNum">     455 </span>                :            : </a>
<a name="456"><span class="lineNum">     456 </span>                :            : template &lt;&gt;</a>
<a name="457"><span class="lineNum">     457 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits&lt;wchar_t&gt;</a>
<a name="458"><span class="lineNum">     458 </span>                :            : {</a>
<a name="459"><span class="lineNum">     459 </span>                :            :     typedef wchar_t   char_type;</a>
<a name="460"><span class="lineNum">     460 </span>                :            :     typedef wint_t    int_type;</a>
<a name="461"><span class="lineNum">     461 </span>                :            :     typedef streamoff off_type;</a>
<a name="462"><span class="lineNum">     462 </span>                :            :     typedef streampos pos_type;</a>
<a name="463"><span class="lineNum">     463 </span>                :            :     typedef mbstate_t state_type;</a>
<a name="464"><span class="lineNum">     464 </span>                :            : </a>
<a name="465"><span class="lineNum">     465 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="466"><span class="lineNum">     466 </span>                :            :     void assign(char_type&amp; __c1, const char_type&amp; __c2) _NOEXCEPT {__c1 = __c2;}</a>
<a name="467"><span class="lineNum">     467 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="468"><span class="lineNum">     468 </span>                :            :         {return __c1 == __c2;}</a>
<a name="469"><span class="lineNum">     469 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="470"><span class="lineNum">     470 </span>                :            :         {return __c1 &lt; __c2;}</a>
<a name="471"><span class="lineNum">     471 </span>                :            : </a>
<a name="472"><span class="lineNum">     472 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="473"><span class="lineNum">     473 </span>                :            :     int compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="474"><span class="lineNum">     474 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="475"><span class="lineNum">     475 </span>                :            :     size_t length(const char_type* __s) _NOEXCEPT;</a>
<a name="476"><span class="lineNum">     476 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="477"><span class="lineNum">     477 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT;</a>
<a name="478"><span class="lineNum">     478 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="479"><span class="lineNum">     479 </span>                :            :     char_type* move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="480"><span class="lineNum">     480 </span>                :            :         {</a>
<a name="481"><span class="lineNum">     481 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="482"><span class="lineNum">     482 </span>                :            :                        ? _VSTD::__move_constexpr(__s1, __s2, __n)</a>
<a name="483"><span class="lineNum">     483 </span>                :            :                        : __n == 0 ? __s1 : _VSTD::wmemmove(__s1, __s2, __n);</a>
<a name="484"><span class="lineNum">     484 </span>                :            :         }</a>
<a name="485"><span class="lineNum">     485 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="486"><span class="lineNum">     486 </span>                :            :     char_type* copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="487"><span class="lineNum">     487 </span>                :            :         {</a>
<a name="488"><span class="lineNum">     488 </span>                :            :             _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="489"><span class="lineNum">     489 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="490"><span class="lineNum">     490 </span>                :            :                        ? _VSTD::__copy_constexpr(__s1, __s2, __n)</a>
<a name="491"><span class="lineNum">     491 </span>                :            :                        : __n == 0 ? __s1 : _VSTD::wmemcpy(__s1, __s2, __n);</a>
<a name="492"><span class="lineNum">     492 </span>                :            :         }</a>
<a name="493"><span class="lineNum">     493 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="494"><span class="lineNum">     494 </span>                :            :     char_type* assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT</a>
<a name="495"><span class="lineNum">     495 </span>                :            :         {</a>
<a name="496"><span class="lineNum">     496 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="497"><span class="lineNum">     497 </span>                :            :                        ? _VSTD::__assign_constexpr(__s, __n, __a)</a>
<a name="498"><span class="lineNum">     498 </span>                :            :                        : __n == 0 ? __s : _VSTD::wmemset(__s, __a, __n);</a>
<a name="499"><span class="lineNum">     499 </span>                :            :         }</a>
<a name="500"><span class="lineNum">     500 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT</a>
<a name="501"><span class="lineNum">     501 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="502"><span class="lineNum">     502 </span>                :            :     static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT</a>
<a name="503"><span class="lineNum">     503 </span>                :            :         {return char_type(__c);}</a>
<a name="504"><span class="lineNum">     504 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT</a>
<a name="505"><span class="lineNum">     505 </span>                :            :         {return int_type(__c);}</a>
<a name="506"><span class="lineNum">     506 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT</a>
<a name="507"><span class="lineNum">     507 </span>                :            :         {return __c1 == __c2;}</a>
<a name="508"><span class="lineNum">     508 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT</a>
<a name="509"><span class="lineNum">     509 </span>                :            :         {return int_type(WEOF);}</a>
<a name="510"><span class="lineNum">     510 </span>                :            : };</a>
<a name="511"><span class="lineNum">     511 </span>                :            : </a>
<a name="512"><span class="lineNum">     512 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="513"><span class="lineNum">     513 </span>                :            : int</a>
<a name="514"><span class="lineNum">     514 </span>                :            : char_traits&lt;wchar_t&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="515"><span class="lineNum">     515 </span>                :            : {</a>
<a name="516"><span class="lineNum">     516 </span>                :            :     if (__n == 0)</a>
<a name="517"><span class="lineNum">     517 </span>                :            :         return 0;</a>
<a name="518"><span class="lineNum">     518 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="519"><span class="lineNum">     519 </span>                :            :     return __builtin_wmemcmp(__s1, __s2, __n);</a>
<a name="520"><span class="lineNum">     520 </span>                :            : #elif _LIBCPP_STD_VER &lt;= 14</a>
<a name="521"><span class="lineNum">     521 </span>                :            :     return _VSTD::wmemcmp(__s1, __s2, __n);</a>
<a name="522"><span class="lineNum">     522 </span>                :            : #else</a>
<a name="523"><span class="lineNum">     523 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="524"><span class="lineNum">     524 </span>                :            :     {</a>
<a name="525"><span class="lineNum">     525 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="526"><span class="lineNum">     526 </span>                :            :             return -1;</a>
<a name="527"><span class="lineNum">     527 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="528"><span class="lineNum">     528 </span>                :            :             return 1;</a>
<a name="529"><span class="lineNum">     529 </span>                :            :     }</a>
<a name="530"><span class="lineNum">     530 </span>                :            :     return 0;</a>
<a name="531"><span class="lineNum">     531 </span>                :            : #endif</a>
<a name="532"><span class="lineNum">     532 </span>                :            : }</a>
<a name="533"><span class="lineNum">     533 </span>                :            : </a>
<a name="534"><span class="lineNum">     534 </span>                :            : </a>
<a name="535"><span class="lineNum">     535 </span>                :            : template &lt;class _Traits&gt;</a>
<a name="536"><span class="lineNum">     536 </span>                :            : _LIBCPP_INLINE_VISIBILITY</a>
<a name="537"><span class="lineNum">     537 </span>                :            : _LIBCPP_CONSTEXPR</a>
<a name="538"><span class="lineNum">     538 </span>                :            : inline size_t __char_traits_length_checked(const typename _Traits::char_type* __s) _NOEXCEPT {</a>
<a name="539"><span class="lineNum">     539 </span>                :            : #if _LIBCPP_DEBUG_LEVEL &gt;= 1</a>
<a name="540"><span class="lineNum">     540 </span>                :            :   return __s ? _Traits::length(__s) : (_VSTD::__libcpp_debug_function(_VSTD::__libcpp_debug_info(__FILE__, __LINE__, &quot;p == nullptr&quot;, &quot;null pointer pass to non-null argument of char_traits&lt;...&gt;::length&quot;)), 0);</a>
<a name="541"><span class="lineNum">     541 </span>                :            : #else</a>
<a name="542"><span class="lineNum">     542 </span>                :            :   return _Traits::length(__s);</a>
<a name="543"><span class="lineNum">     543 </span>                :            : #endif</a>
<a name="544"><span class="lineNum">     544 </span>                :            : }</a>
<a name="545"><span class="lineNum">     545 </span>                :            : </a>
<a name="546"><span class="lineNum">     546 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="547"><span class="lineNum">     547 </span>                :            : size_t</a>
<a name="548"><span class="lineNum">     548 </span>                :            : char_traits&lt;wchar_t&gt;::length(const char_type* __s) _NOEXCEPT</a>
<a name="549"><span class="lineNum">     549 </span>                :            : {</a>
<a name="550"><span class="lineNum">     550 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="551"><span class="lineNum">     551 </span>                :            :     return __builtin_wcslen(__s);</a>
<a name="552"><span class="lineNum">     552 </span>                :            : #elif _LIBCPP_STD_VER &lt;= 14</a>
<a name="553"><span class="lineNum">     553 </span>                :            :     return _VSTD::wcslen(__s);</a>
<a name="554"><span class="lineNum">     554 </span>                :            : #else</a>
<a name="555"><span class="lineNum">     555 </span>                :            :     size_t __len = 0;</a>
<a name="556"><span class="lineNum">     556 </span>                :            :     for (; !eq(*__s, char_type(0)); ++__s)</a>
<a name="557"><span class="lineNum">     557 </span>                :            :         ++__len;</a>
<a name="558"><span class="lineNum">     558 </span>                :            :     return __len;</a>
<a name="559"><span class="lineNum">     559 </span>                :            : #endif</a>
<a name="560"><span class="lineNum">     560 </span>                :            : }</a>
<a name="561"><span class="lineNum">     561 </span>                :            : </a>
<a name="562"><span class="lineNum">     562 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="563"><span class="lineNum">     563 </span>                :            : const wchar_t*</a>
<a name="564"><span class="lineNum">     564 </span>                :            : char_traits&lt;wchar_t&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT</a>
<a name="565"><span class="lineNum">     565 </span>                :            : {</a>
<a name="566"><span class="lineNum">     566 </span>                :            :     if (__n == 0)</a>
<a name="567"><span class="lineNum">     567 </span>                :            :         return nullptr;</a>
<a name="568"><span class="lineNum">     568 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="569"><span class="lineNum">     569 </span>                :            :     return __builtin_wmemchr(__s, __a, __n);</a>
<a name="570"><span class="lineNum">     570 </span>                :            : #elif _LIBCPP_STD_VER &lt;= 14</a>
<a name="571"><span class="lineNum">     571 </span>                :            :     return _VSTD::wmemchr(__s, __a, __n);</a>
<a name="572"><span class="lineNum">     572 </span>                :            : #else</a>
<a name="573"><span class="lineNum">     573 </span>                :            :     for (; __n; --__n)</a>
<a name="574"><span class="lineNum">     574 </span>                :            :     {</a>
<a name="575"><span class="lineNum">     575 </span>                :            :         if (eq(*__s, __a))</a>
<a name="576"><span class="lineNum">     576 </span>                :            :             return __s;</a>
<a name="577"><span class="lineNum">     577 </span>                :            :         ++__s;</a>
<a name="578"><span class="lineNum">     578 </span>                :            :     }</a>
<a name="579"><span class="lineNum">     579 </span>                :            :     return nullptr;</a>
<a name="580"><span class="lineNum">     580 </span>                :            : #endif</a>
<a name="581"><span class="lineNum">     581 </span>                :            : }</a>
<a name="582"><span class="lineNum">     582 </span>                :            : </a>
<a name="583"><span class="lineNum">     583 </span>                :            : </a>
<a name="584"><span class="lineNum">     584 </span>                :            : #ifndef _LIBCPP_NO_HAS_CHAR8_T</a>
<a name="585"><span class="lineNum">     585 </span>                :            : </a>
<a name="586"><span class="lineNum">     586 </span>                :            : template &lt;&gt;</a>
<a name="587"><span class="lineNum">     587 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits&lt;char8_t&gt;</a>
<a name="588"><span class="lineNum">     588 </span>                :            : {</a>
<a name="589"><span class="lineNum">     589 </span>                :            :     typedef char8_t        char_type;</a>
<a name="590"><span class="lineNum">     590 </span>                :            :     typedef unsigned int   int_type;</a>
<a name="591"><span class="lineNum">     591 </span>                :            :     typedef streamoff      off_type;</a>
<a name="592"><span class="lineNum">     592 </span>                :            :     typedef u8streampos    pos_type;</a>
<a name="593"><span class="lineNum">     593 </span>                :            :     typedef mbstate_t      state_type;</a>
<a name="594"><span class="lineNum">     594 </span>                :            : </a>
<a name="595"><span class="lineNum">     595 </span>                :            :     static inline constexpr void assign(char_type&amp; __c1, const char_type&amp; __c2) noexcept</a>
<a name="596"><span class="lineNum">     596 </span>                :            :         {__c1 = __c2;}</a>
<a name="597"><span class="lineNum">     597 </span>                :            :     static inline constexpr bool eq(char_type __c1, char_type __c2) noexcept</a>
<a name="598"><span class="lineNum">     598 </span>                :            :         {return __c1 == __c2;}</a>
<a name="599"><span class="lineNum">     599 </span>                :            :     static inline constexpr bool lt(char_type __c1, char_type __c2) noexcept</a>
<a name="600"><span class="lineNum">     600 </span>                :            :         {return __c1 &lt; __c2;}</a>
<a name="601"><span class="lineNum">     601 </span>                :            : </a>
<a name="602"><span class="lineNum">     602 </span>                :            :     static constexpr</a>
<a name="603"><span class="lineNum">     603 </span>                :            :     int              compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="604"><span class="lineNum">     604 </span>                :            : </a>
<a name="605"><span class="lineNum">     605 </span>                :            :     static constexpr</a>
<a name="606"><span class="lineNum">     606 </span>                :            :     size_t           length(const char_type* __s) _NOEXCEPT;</a>
<a name="607"><span class="lineNum">     607 </span>                :            : </a>
<a name="608"><span class="lineNum">     608 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static constexpr</a>
<a name="609"><span class="lineNum">     609 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT;</a>
<a name="610"><span class="lineNum">     610 </span>                :            : </a>
<a name="611"><span class="lineNum">     611 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="612"><span class="lineNum">     612 </span>                :            :     char_type*       move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="613"><span class="lineNum">     613 </span>                :            :         {</a>
<a name="614"><span class="lineNum">     614 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="615"><span class="lineNum">     615 </span>                :            :                        ? _VSTD::__move_constexpr(__s1, __s2, __n)</a>
<a name="616"><span class="lineNum">     616 </span>                :            :                        : __n == 0 ? __s1 : (char_type*)_VSTD::memmove(__s1, __s2, __n);</a>
<a name="617"><span class="lineNum">     617 </span>                :            :         }</a>
<a name="618"><span class="lineNum">     618 </span>                :            : </a>
<a name="619"><span class="lineNum">     619 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="620"><span class="lineNum">     620 </span>                :            :     char_type*       copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="621"><span class="lineNum">     621 </span>                :            :        {</a>
<a name="622"><span class="lineNum">     622 </span>                :            :             _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="623"><span class="lineNum">     623 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="624"><span class="lineNum">     624 </span>                :            :                        ? _VSTD::__copy_constexpr(__s1, __s2, __n)</a>
<a name="625"><span class="lineNum">     625 </span>                :            :                        : __n == 0 ? __s1 : (char_type*)_VSTD::memcpy(__s1, __s2, __n);</a>
<a name="626"><span class="lineNum">     626 </span>                :            :         }</a>
<a name="627"><span class="lineNum">     627 </span>                :            : </a>
<a name="628"><span class="lineNum">     628 </span>                :            :     static _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="629"><span class="lineNum">     629 </span>                :            :     char_type*       assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT</a>
<a name="630"><span class="lineNum">     630 </span>                :            :         {</a>
<a name="631"><span class="lineNum">     631 </span>                :            :             return __libcpp_is_constant_evaluated()</a>
<a name="632"><span class="lineNum">     632 </span>                :            :                        ? _VSTD::__assign_constexpr(__s, __n, __a)</a>
<a name="633"><span class="lineNum">     633 </span>                :            :                        : __n == 0 ? __s : (char_type*)_VSTD::memset(__s, to_int_type(__a), __n);</a>
<a name="634"><span class="lineNum">     634 </span>                :            :         }</a>
<a name="635"><span class="lineNum">     635 </span>                :            : </a>
<a name="636"><span class="lineNum">     636 </span>                :            :     static inline constexpr int_type  not_eof(int_type __c) noexcept</a>
<a name="637"><span class="lineNum">     637 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="638"><span class="lineNum">     638 </span>                :            :     static inline constexpr char_type to_char_type(int_type __c) noexcept</a>
<a name="639"><span class="lineNum">     639 </span>                :            :         {return char_type(__c);}</a>
<a name="640"><span class="lineNum">     640 </span>                :            :     static inline constexpr int_type to_int_type(char_type __c) noexcept</a>
<a name="641"><span class="lineNum">     641 </span>                :            :         {return int_type(__c);}</a>
<a name="642"><span class="lineNum">     642 </span>                :            :     static inline constexpr bool eq_int_type(int_type __c1, int_type __c2) noexcept</a>
<a name="643"><span class="lineNum">     643 </span>                :            :         {return __c1 == __c2;}</a>
<a name="644"><span class="lineNum">     644 </span>                :            :     static inline constexpr int_type eof() noexcept</a>
<a name="645"><span class="lineNum">     645 </span>                :            :         {return int_type(EOF);}</a>
<a name="646"><span class="lineNum">     646 </span>                :            : };</a>
<a name="647"><span class="lineNum">     647 </span>                :            : </a>
<a name="648"><span class="lineNum">     648 </span>                :            : // TODO use '__builtin_strlen' if it ever supports char8_t ??</a>
<a name="649"><span class="lineNum">     649 </span>                :            : inline constexpr</a>
<a name="650"><span class="lineNum">     650 </span>                :            : size_t</a>
<a name="651"><span class="lineNum">     651 </span>                :            : char_traits&lt;char8_t&gt;::length(const char_type* __s) _NOEXCEPT</a>
<a name="652"><span class="lineNum">     652 </span>                :            : {</a>
<a name="653"><span class="lineNum">     653 </span>                :            :     size_t __len = 0;</a>
<a name="654"><span class="lineNum">     654 </span>                :            :     for (; !eq(*__s, char_type(0)); ++__s)</a>
<a name="655"><span class="lineNum">     655 </span>                :            :         ++__len;</a>
<a name="656"><span class="lineNum">     656 </span>                :            :     return __len;</a>
<a name="657"><span class="lineNum">     657 </span>                :            : }</a>
<a name="658"><span class="lineNum">     658 </span>                :            : </a>
<a name="659"><span class="lineNum">     659 </span>                :            : inline constexpr</a>
<a name="660"><span class="lineNum">     660 </span>                :            : int</a>
<a name="661"><span class="lineNum">     661 </span>                :            : char_traits&lt;char8_t&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="662"><span class="lineNum">     662 </span>                :            : {</a>
<a name="663"><span class="lineNum">     663 </span>                :            : #if __has_feature(cxx_constexpr_string_builtins)</a>
<a name="664"><span class="lineNum">     664 </span>                :            :     return __builtin_memcmp(__s1, __s2, __n);</a>
<a name="665"><span class="lineNum">     665 </span>                :            : #else</a>
<a name="666"><span class="lineNum">     666 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="667"><span class="lineNum">     667 </span>                :            :     {</a>
<a name="668"><span class="lineNum">     668 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="669"><span class="lineNum">     669 </span>                :            :             return -1;</a>
<a name="670"><span class="lineNum">     670 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="671"><span class="lineNum">     671 </span>                :            :             return 1;</a>
<a name="672"><span class="lineNum">     672 </span>                :            :     }</a>
<a name="673"><span class="lineNum">     673 </span>                :            :     return 0;</a>
<a name="674"><span class="lineNum">     674 </span>                :            : #endif</a>
<a name="675"><span class="lineNum">     675 </span>                :            : }</a>
<a name="676"><span class="lineNum">     676 </span>                :            : </a>
<a name="677"><span class="lineNum">     677 </span>                :            : // TODO use '__builtin_char_memchr' if it ever supports char8_t ??</a>
<a name="678"><span class="lineNum">     678 </span>                :            : inline constexpr</a>
<a name="679"><span class="lineNum">     679 </span>                :            : const char8_t*</a>
<a name="680"><span class="lineNum">     680 </span>                :            : char_traits&lt;char8_t&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT</a>
<a name="681"><span class="lineNum">     681 </span>                :            : {</a>
<a name="682"><span class="lineNum">     682 </span>                :            :     for (; __n; --__n)</a>
<a name="683"><span class="lineNum">     683 </span>                :            :     {</a>
<a name="684"><span class="lineNum">     684 </span>                :            :         if (eq(*__s, __a))</a>
<a name="685"><span class="lineNum">     685 </span>                :            :             return __s;</a>
<a name="686"><span class="lineNum">     686 </span>                :            :         ++__s;</a>
<a name="687"><span class="lineNum">     687 </span>                :            :     }</a>
<a name="688"><span class="lineNum">     688 </span>                :            :     return nullptr;</a>
<a name="689"><span class="lineNum">     689 </span>                :            : }</a>
<a name="690"><span class="lineNum">     690 </span>                :            : </a>
<a name="691"><span class="lineNum">     691 </span>                :            : #endif // #_LIBCPP_NO_HAS_CHAR8_T</a>
<a name="692"><span class="lineNum">     692 </span>                :            : </a>
<a name="693"><span class="lineNum">     693 </span>                :            : #ifndef _LIBCPP_HAS_NO_UNICODE_CHARS</a>
<a name="694"><span class="lineNum">     694 </span>                :            : </a>
<a name="695"><span class="lineNum">     695 </span>                :            : template &lt;&gt;</a>
<a name="696"><span class="lineNum">     696 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits&lt;char16_t&gt;</a>
<a name="697"><span class="lineNum">     697 </span>                :            : {</a>
<a name="698"><span class="lineNum">     698 </span>                :            :     typedef char16_t       char_type;</a>
<a name="699"><span class="lineNum">     699 </span>                :            :     typedef uint_least16_t int_type;</a>
<a name="700"><span class="lineNum">     700 </span>                :            :     typedef streamoff      off_type;</a>
<a name="701"><span class="lineNum">     701 </span>                :            :     typedef u16streampos   pos_type;</a>
<a name="702"><span class="lineNum">     702 </span>                :            :     typedef mbstate_t      state_type;</a>
<a name="703"><span class="lineNum">     703 </span>                :            : </a>
<a name="704"><span class="lineNum">     704 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="705"><span class="lineNum">     705 </span>                :            :     void assign(char_type&amp; __c1, const char_type&amp; __c2) _NOEXCEPT {__c1 = __c2;}</a>
<a name="706"><span class="lineNum">     706 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="707"><span class="lineNum">     707 </span>                :            :         {return __c1 == __c2;}</a>
<a name="708"><span class="lineNum">     708 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="709"><span class="lineNum">     709 </span>                :            :         {return __c1 &lt; __c2;}</a>
<a name="710"><span class="lineNum">     710 </span>                :            : </a>
<a name="711"><span class="lineNum">     711 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="712"><span class="lineNum">     712 </span>                :            :     int              compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="713"><span class="lineNum">     713 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="714"><span class="lineNum">     714 </span>                :            :     size_t           length(const char_type* __s) _NOEXCEPT;</a>
<a name="715"><span class="lineNum">     715 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="716"><span class="lineNum">     716 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT;</a>
<a name="717"><span class="lineNum">     717 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="718"><span class="lineNum">     718 </span>                :            :     static char_type*       move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="719"><span class="lineNum">     719 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="720"><span class="lineNum">     720 </span>                :            :     static char_type*       copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="721"><span class="lineNum">     721 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="722"><span class="lineNum">     722 </span>                :            :     static char_type*       assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT;</a>
<a name="723"><span class="lineNum">     723 </span>                :            : </a>
<a name="724"><span class="lineNum">     724 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT</a>
<a name="725"><span class="lineNum">     725 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="726"><span class="lineNum">     726 </span>                :            :     static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT</a>
<a name="727"><span class="lineNum">     727 </span>                :            :         {return char_type(__c);}</a>
<a name="728"><span class="lineNum">     728 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT</a>
<a name="729"><span class="lineNum">     729 </span>                :            :         {return int_type(__c);}</a>
<a name="730"><span class="lineNum">     730 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT</a>
<a name="731"><span class="lineNum">     731 </span>                :            :         {return __c1 == __c2;}</a>
<a name="732"><span class="lineNum">     732 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT</a>
<a name="733"><span class="lineNum">     733 </span>                :            :         {return int_type(0xFFFF);}</a>
<a name="734"><span class="lineNum">     734 </span>                :            : };</a>
<a name="735"><span class="lineNum">     735 </span>                :            : </a>
<a name="736"><span class="lineNum">     736 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="737"><span class="lineNum">     737 </span>                :            : int</a>
<a name="738"><span class="lineNum">     738 </span>                :            : char_traits&lt;char16_t&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="739"><span class="lineNum">     739 </span>                :            : {</a>
<a name="740"><span class="lineNum">     740 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="741"><span class="lineNum">     741 </span>                :            :     {</a>
<a name="742"><span class="lineNum">     742 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="743"><span class="lineNum">     743 </span>                :            :             return -1;</a>
<a name="744"><span class="lineNum">     744 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="745"><span class="lineNum">     745 </span>                :            :             return 1;</a>
<a name="746"><span class="lineNum">     746 </span>                :            :     }</a>
<a name="747"><span class="lineNum">     747 </span>                :            :     return 0;</a>
<a name="748"><span class="lineNum">     748 </span>                :            : }</a>
<a name="749"><span class="lineNum">     749 </span>                :            : </a>
<a name="750"><span class="lineNum">     750 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="751"><span class="lineNum">     751 </span>                :            : size_t</a>
<a name="752"><span class="lineNum">     752 </span>                :            : char_traits&lt;char16_t&gt;::length(const char_type* __s) _NOEXCEPT</a>
<a name="753"><span class="lineNum">     753 </span>                :            : {</a>
<a name="754"><span class="lineNum">     754 </span>                :            :     size_t __len = 0;</a>
<a name="755"><span class="lineNum">     755 </span>                :            :     for (; !eq(*__s, char_type(0)); ++__s)</a>
<a name="756"><span class="lineNum">     756 </span>                :            :         ++__len;</a>
<a name="757"><span class="lineNum">     757 </span>                :            :     return __len;</a>
<a name="758"><span class="lineNum">     758 </span>                :            : }</a>
<a name="759"><span class="lineNum">     759 </span>                :            : </a>
<a name="760"><span class="lineNum">     760 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="761"><span class="lineNum">     761 </span>                :            : const char16_t*</a>
<a name="762"><span class="lineNum">     762 </span>                :            : char_traits&lt;char16_t&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT</a>
<a name="763"><span class="lineNum">     763 </span>                :            : {</a>
<a name="764"><span class="lineNum">     764 </span>                :            :     for (; __n; --__n)</a>
<a name="765"><span class="lineNum">     765 </span>                :            :     {</a>
<a name="766"><span class="lineNum">     766 </span>                :            :         if (eq(*__s, __a))</a>
<a name="767"><span class="lineNum">     767 </span>                :            :             return __s;</a>
<a name="768"><span class="lineNum">     768 </span>                :            :         ++__s;</a>
<a name="769"><span class="lineNum">     769 </span>                :            :     }</a>
<a name="770"><span class="lineNum">     770 </span>                :            :     return nullptr;</a>
<a name="771"><span class="lineNum">     771 </span>                :            : }</a>
<a name="772"><span class="lineNum">     772 </span>                :            : </a>
<a name="773"><span class="lineNum">     773 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="774"><span class="lineNum">     774 </span>                :            : char16_t*</a>
<a name="775"><span class="lineNum">     775 </span>                :            : char_traits&lt;char16_t&gt;::move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="776"><span class="lineNum">     776 </span>                :            : {</a>
<a name="777"><span class="lineNum">     777 </span>                :            :     if (__n == 0) return __s1;</a>
<a name="778"><span class="lineNum">     778 </span>                :            :     char_type* __r = __s1;</a>
<a name="779"><span class="lineNum">     779 </span>                :            :     if (__s1 &lt; __s2)</a>
<a name="780"><span class="lineNum">     780 </span>                :            :     {</a>
<a name="781"><span class="lineNum">     781 </span>                :            :         for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="782"><span class="lineNum">     782 </span>                :            :             assign(*__s1, *__s2);</a>
<a name="783"><span class="lineNum">     783 </span>                :            :     }</a>
<a name="784"><span class="lineNum">     784 </span>                :            :     else if (__s2 &lt; __s1)</a>
<a name="785"><span class="lineNum">     785 </span>                :            :     {</a>
<a name="786"><span class="lineNum">     786 </span>                :            :         __s1 += __n;</a>
<a name="787"><span class="lineNum">     787 </span>                :            :         __s2 += __n;</a>
<a name="788"><span class="lineNum">     788 </span>                :            :         for (; __n; --__n)</a>
<a name="789"><span class="lineNum">     789 </span>                :            :             assign(*--__s1, *--__s2);</a>
<a name="790"><span class="lineNum">     790 </span>                :            :     }</a>
<a name="791"><span class="lineNum">     791 </span>                :            :     return __r;</a>
<a name="792"><span class="lineNum">     792 </span>                :            : }</a>
<a name="793"><span class="lineNum">     793 </span>                :            : </a>
<a name="794"><span class="lineNum">     794 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="795"><span class="lineNum">     795 </span>                :            : char16_t*</a>
<a name="796"><span class="lineNum">     796 </span>                :            : char_traits&lt;char16_t&gt;::copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="797"><span class="lineNum">     797 </span>                :            : {</a>
<a name="798"><span class="lineNum">     798 </span>                :            :     _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="799"><span class="lineNum">     799 </span>                :            :     char_type* __r = __s1;</a>
<a name="800"><span class="lineNum">     800 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="801"><span class="lineNum">     801 </span>                :            :         assign(*__s1, *__s2);</a>
<a name="802"><span class="lineNum">     802 </span>                :            :     return __r;</a>
<a name="803"><span class="lineNum">     803 </span>                :            : }</a>
<a name="804"><span class="lineNum">     804 </span>                :            : </a>
<a name="805"><span class="lineNum">     805 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="806"><span class="lineNum">     806 </span>                :            : char16_t*</a>
<a name="807"><span class="lineNum">     807 </span>                :            : char_traits&lt;char16_t&gt;::assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT</a>
<a name="808"><span class="lineNum">     808 </span>                :            : {</a>
<a name="809"><span class="lineNum">     809 </span>                :            :     char_type* __r = __s;</a>
<a name="810"><span class="lineNum">     810 </span>                :            :     for (; __n; --__n, ++__s)</a>
<a name="811"><span class="lineNum">     811 </span>                :            :         assign(*__s, __a);</a>
<a name="812"><span class="lineNum">     812 </span>                :            :     return __r;</a>
<a name="813"><span class="lineNum">     813 </span>                :            : }</a>
<a name="814"><span class="lineNum">     814 </span>                :            : </a>
<a name="815"><span class="lineNum">     815 </span>                :            : template &lt;&gt;</a>
<a name="816"><span class="lineNum">     816 </span>                :            : struct _LIBCPP_TEMPLATE_VIS char_traits&lt;char32_t&gt;</a>
<a name="817"><span class="lineNum">     817 </span>                :            : {</a>
<a name="818"><span class="lineNum">     818 </span>                :            :     typedef char32_t       char_type;</a>
<a name="819"><span class="lineNum">     819 </span>                :            :     typedef uint_least32_t int_type;</a>
<a name="820"><span class="lineNum">     820 </span>                :            :     typedef streamoff      off_type;</a>
<a name="821"><span class="lineNum">     821 </span>                :            :     typedef u32streampos   pos_type;</a>
<a name="822"><span class="lineNum">     822 </span>                :            :     typedef mbstate_t      state_type;</a>
<a name="823"><span class="lineNum">     823 </span>                :            : </a>
<a name="824"><span class="lineNum">     824 </span>                :            :     static inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="825"><span class="lineNum">     825 </span>                :            :     void assign(char_type&amp; __c1, const char_type&amp; __c2) _NOEXCEPT {__c1 = __c2;}</a>
<a name="826"><span class="lineNum">     826 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="827"><span class="lineNum">     827 </span>                :            :         {return __c1 == __c2;}</a>
<a name="828"><span class="lineNum">     828 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool lt(char_type __c1, char_type __c2) _NOEXCEPT</a>
<a name="829"><span class="lineNum">     829 </span>                :            :         {return __c1 &lt; __c2;}</a>
<a name="830"><span class="lineNum">     830 </span>                :            : </a>
<a name="831"><span class="lineNum">     831 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="832"><span class="lineNum">     832 </span>                :            :     int              compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="833"><span class="lineNum">     833 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="834"><span class="lineNum">     834 </span>                :            :     size_t           length(const char_type* __s) _NOEXCEPT;</a>
<a name="835"><span class="lineNum">     835 </span>                :            :     _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="836"><span class="lineNum">     836 </span>                :            :     const char_type* find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT;</a>
<a name="837"><span class="lineNum">     837 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="838"><span class="lineNum">     838 </span>                :            :     static char_type*       move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="839"><span class="lineNum">     839 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="840"><span class="lineNum">     840 </span>                :            :     static char_type*       copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT;</a>
<a name="841"><span class="lineNum">     841 </span>                :            :     _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="842"><span class="lineNum">     842 </span>                :            :     static char_type*       assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT;</a>
<a name="843"><span class="lineNum">     843 </span>                :            : </a>
<a name="844"><span class="lineNum">     844 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type  not_eof(int_type __c) _NOEXCEPT</a>
<a name="845"><span class="lineNum">     845 </span>                :            :         {return eq_int_type(__c, eof()) ? ~eof() : __c;}</a>
<a name="846"><span class="lineNum">     846 </span>                :            :     static inline _LIBCPP_CONSTEXPR char_type to_char_type(int_type __c) _NOEXCEPT</a>
<a name="847"><span class="lineNum">     847 </span>                :            :         {return char_type(__c);}</a>
<a name="848"><span class="lineNum">     848 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type to_int_type(char_type __c) _NOEXCEPT</a>
<a name="849"><span class="lineNum">     849 </span>                :            :         {return int_type(__c);}</a>
<a name="850"><span class="lineNum">     850 </span>                :            :     static inline _LIBCPP_CONSTEXPR bool eq_int_type(int_type __c1, int_type __c2) _NOEXCEPT</a>
<a name="851"><span class="lineNum">     851 </span>                :            :         {return __c1 == __c2;}</a>
<a name="852"><span class="lineNum">     852 </span>                :            :     static inline _LIBCPP_CONSTEXPR int_type eof() _NOEXCEPT</a>
<a name="853"><span class="lineNum">     853 </span>                :            :         {return int_type(0xFFFFFFFF);}</a>
<a name="854"><span class="lineNum">     854 </span>                :            : };</a>
<a name="855"><span class="lineNum">     855 </span>                :            : </a>
<a name="856"><span class="lineNum">     856 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="857"><span class="lineNum">     857 </span>                :            : int</a>
<a name="858"><span class="lineNum">     858 </span>                :            : char_traits&lt;char32_t&gt;::compare(const char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="859"><span class="lineNum">     859 </span>                :            : {</a>
<a name="860"><span class="lineNum">     860 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="861"><span class="lineNum">     861 </span>                :            :     {</a>
<a name="862"><span class="lineNum">     862 </span>                :            :         if (lt(*__s1, *__s2))</a>
<a name="863"><span class="lineNum">     863 </span>                :            :             return -1;</a>
<a name="864"><span class="lineNum">     864 </span>                :            :         if (lt(*__s2, *__s1))</a>
<a name="865"><span class="lineNum">     865 </span>                :            :             return 1;</a>
<a name="866"><span class="lineNum">     866 </span>                :            :     }</a>
<a name="867"><span class="lineNum">     867 </span>                :            :     return 0;</a>
<a name="868"><span class="lineNum">     868 </span>                :            : }</a>
<a name="869"><span class="lineNum">     869 </span>                :            : </a>
<a name="870"><span class="lineNum">     870 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="871"><span class="lineNum">     871 </span>                :            : size_t</a>
<a name="872"><span class="lineNum">     872 </span>                :            : char_traits&lt;char32_t&gt;::length(const char_type* __s) _NOEXCEPT</a>
<a name="873"><span class="lineNum">     873 </span>                :            : {</a>
<a name="874"><span class="lineNum">     874 </span>                :            :     size_t __len = 0;</a>
<a name="875"><span class="lineNum">     875 </span>                :            :     for (; !eq(*__s, char_type(0)); ++__s)</a>
<a name="876"><span class="lineNum">     876 </span>                :            :         ++__len;</a>
<a name="877"><span class="lineNum">     877 </span>                :            :     return __len;</a>
<a name="878"><span class="lineNum">     878 </span>                :            : }</a>
<a name="879"><span class="lineNum">     879 </span>                :            : </a>
<a name="880"><span class="lineNum">     880 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX14</a>
<a name="881"><span class="lineNum">     881 </span>                :            : const char32_t*</a>
<a name="882"><span class="lineNum">     882 </span>                :            : char_traits&lt;char32_t&gt;::find(const char_type* __s, size_t __n, const char_type&amp; __a) _NOEXCEPT</a>
<a name="883"><span class="lineNum">     883 </span>                :            : {</a>
<a name="884"><span class="lineNum">     884 </span>                :            :     for (; __n; --__n)</a>
<a name="885"><span class="lineNum">     885 </span>                :            :     {</a>
<a name="886"><span class="lineNum">     886 </span>                :            :         if (eq(*__s, __a))</a>
<a name="887"><span class="lineNum">     887 </span>                :            :             return __s;</a>
<a name="888"><span class="lineNum">     888 </span>                :            :         ++__s;</a>
<a name="889"><span class="lineNum">     889 </span>                :            :     }</a>
<a name="890"><span class="lineNum">     890 </span>                :            :     return nullptr;</a>
<a name="891"><span class="lineNum">     891 </span>                :            : }</a>
<a name="892"><span class="lineNum">     892 </span>                :            : </a>
<a name="893"><span class="lineNum">     893 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="894"><span class="lineNum">     894 </span>                :            : char32_t*</a>
<a name="895"><span class="lineNum">     895 </span>                :            : char_traits&lt;char32_t&gt;::move(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="896"><span class="lineNum">     896 </span>                :            : {</a>
<a name="897"><span class="lineNum">     897 </span>                :            :     if (__n == 0) return __s1;</a>
<a name="898"><span class="lineNum">     898 </span>                :            :     char_type* __r = __s1;</a>
<a name="899"><span class="lineNum">     899 </span>                :            :     if (__s1 &lt; __s2)</a>
<a name="900"><span class="lineNum">     900 </span>                :            :     {</a>
<a name="901"><span class="lineNum">     901 </span>                :            :         for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="902"><span class="lineNum">     902 </span>                :            :             assign(*__s1, *__s2);</a>
<a name="903"><span class="lineNum">     903 </span>                :            :     }</a>
<a name="904"><span class="lineNum">     904 </span>                :            :     else if (__s2 &lt; __s1)</a>
<a name="905"><span class="lineNum">     905 </span>                :            :     {</a>
<a name="906"><span class="lineNum">     906 </span>                :            :         __s1 += __n;</a>
<a name="907"><span class="lineNum">     907 </span>                :            :         __s2 += __n;</a>
<a name="908"><span class="lineNum">     908 </span>                :            :         for (; __n; --__n)</a>
<a name="909"><span class="lineNum">     909 </span>                :            :             assign(*--__s1, *--__s2);</a>
<a name="910"><span class="lineNum">     910 </span>                :            :     }</a>
<a name="911"><span class="lineNum">     911 </span>                :            :     return __r;</a>
<a name="912"><span class="lineNum">     912 </span>                :            : }</a>
<a name="913"><span class="lineNum">     913 </span>                :            : </a>
<a name="914"><span class="lineNum">     914 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="915"><span class="lineNum">     915 </span>                :            : char32_t*</a>
<a name="916"><span class="lineNum">     916 </span>                :            : char_traits&lt;char32_t&gt;::copy(char_type* __s1, const char_type* __s2, size_t __n) _NOEXCEPT</a>
<a name="917"><span class="lineNum">     917 </span>                :            : {</a>
<a name="918"><span class="lineNum">     918 </span>                :            :     _LIBCPP_ASSERT(__s2 &lt; __s1 || __s2 &gt;= __s1+__n, &quot;char_traits::copy overlapped range&quot;);</a>
<a name="919"><span class="lineNum">     919 </span>                :            :     char_type* __r = __s1;</a>
<a name="920"><span class="lineNum">     920 </span>                :            :     for (; __n; --__n, ++__s1, ++__s2)</a>
<a name="921"><span class="lineNum">     921 </span>                :            :         assign(*__s1, *__s2);</a>
<a name="922"><span class="lineNum">     922 </span>                :            :     return __r;</a>
<a name="923"><span class="lineNum">     923 </span>                :            : }</a>
<a name="924"><span class="lineNum">     924 </span>                :            : </a>
<a name="925"><span class="lineNum">     925 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX17</a>
<a name="926"><span class="lineNum">     926 </span>                :            : char32_t*</a>
<a name="927"><span class="lineNum">     927 </span>                :            : char_traits&lt;char32_t&gt;::assign(char_type* __s, size_t __n, char_type __a) _NOEXCEPT</a>
<a name="928"><span class="lineNum">     928 </span>                :            : {</a>
<a name="929"><span class="lineNum">     929 </span>                :            :     char_type* __r = __s;</a>
<a name="930"><span class="lineNum">     930 </span>                :            :     for (; __n; --__n, ++__s)</a>
<a name="931"><span class="lineNum">     931 </span>                :            :         assign(*__s, __a);</a>
<a name="932"><span class="lineNum">     932 </span>                :            :     return __r;</a>
<a name="933"><span class="lineNum">     933 </span>                :            : }</a>
<a name="934"><span class="lineNum">     934 </span>                :            : </a>
<a name="935"><span class="lineNum">     935 </span>                :            : #endif  // _LIBCPP_HAS_NO_UNICODE_CHARS</a>
<a name="936"><span class="lineNum">     936 </span>                :            : </a>
<a name="937"><span class="lineNum">     937 </span>                :            : // helper fns for basic_string and string_view</a>
<a name="938"><span class="lineNum">     938 </span>                :            : </a>
<a name="939"><span class="lineNum">     939 </span>                :            : // __str_find</a>
<a name="940"><span class="lineNum">     940 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="941"><span class="lineNum">     941 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="942"><span class="lineNum">     942 </span>                :            : __str_find(const _CharT *__p, _SizeT __sz,</a>
<a name="943"><span class="lineNum">     943 </span>                :            :              _CharT __c, _SizeT __pos) _NOEXCEPT</a>
<a name="944"><span class="lineNum">     944 </span>                :            : {</a>
<a name="945"><span class="lineNum">     945 </span>                :            :     if (__pos &gt;= __sz)</a>
<a name="946"><span class="lineNum">     946 </span>                :            :         return __npos;</a>
<a name="947"><span class="lineNum">     947 </span>                :            :     const _CharT* __r = _Traits::find(__p + __pos, __sz - __pos, __c);</a>
<a name="948"><span class="lineNum">     948 </span>                :            :     if (__r == nullptr)</a>
<a name="949"><span class="lineNum">     949 </span>                :            :         return __npos;</a>
<a name="950"><span class="lineNum">     950 </span>                :            :     return static_cast&lt;_SizeT&gt;(__r - __p);</a>
<a name="951"><span class="lineNum">     951 </span>                :            : }</a>
<a name="952"><span class="lineNum">     952 </span>                :            : </a>
<a name="953"><span class="lineNum">     953 </span>                :            : template &lt;class _CharT, class _Traits&gt;</a>
<a name="954"><span class="lineNum">     954 </span>                :            : inline _LIBCPP_CONSTEXPR_AFTER_CXX11 const _CharT *</a>
<a name="955"><span class="lineNum">     955 </span>                :            : __search_substring(const _CharT *__first1, const _CharT *__last1,</a>
<a name="956"><span class="lineNum">     956 </span>                :            :                    const _CharT *__first2, const _CharT *__last2) {</a>
<a name="957"><span class="lineNum">     957 </span>                :            :   // Take advantage of knowing source and pattern lengths.</a>
<a name="958"><span class="lineNum">     958 </span>                :            :   // Stop short when source is smaller than pattern.</a>
<a name="959"><span class="lineNum">     959 </span>                :            :   const ptrdiff_t __len2 = __last2 - __first2;</a>
<a name="960"><span class="lineNum">     960 </span>                :            :   if (__len2 == 0)</a>
<a name="961"><span class="lineNum">     961 </span>                :            :     return __first1;</a>
<a name="962"><span class="lineNum">     962 </span>                :            : </a>
<a name="963"><span class="lineNum">     963 </span>                :            :   ptrdiff_t __len1 = __last1 - __first1;</a>
<a name="964"><span class="lineNum">     964 </span>                :            :   if (__len1 &lt; __len2)</a>
<a name="965"><span class="lineNum">     965 </span>                :            :     return __last1;</a>
<a name="966"><span class="lineNum">     966 </span>                :            : </a>
<a name="967"><span class="lineNum">     967 </span>                :            :   // First element of __first2 is loop invariant.</a>
<a name="968"><span class="lineNum">     968 </span>                :            :   _CharT __f2 = *__first2;</a>
<a name="969"><span class="lineNum">     969 </span>                :            :   while (true) {</a>
<a name="970"><span class="lineNum">     970 </span>                :            :     __len1 = __last1 - __first1;</a>
<a name="971"><span class="lineNum">     971 </span>                :            :     // Check whether __first1 still has at least __len2 bytes.</a>
<a name="972"><span class="lineNum">     972 </span>                :            :     if (__len1 &lt; __len2)</a>
<a name="973"><span class="lineNum">     973 </span>                :            :       return __last1;</a>
<a name="974"><span class="lineNum">     974 </span>                :            : </a>
<a name="975"><span class="lineNum">     975 </span>                :            :     // Find __f2 the first byte matching in __first1.</a>
<a name="976"><span class="lineNum">     976 </span>                :            :     __first1 = _Traits::find(__first1, __len1 - __len2 + 1, __f2);</a>
<a name="977"><span class="lineNum">     977 </span>                :            :     if (__first1 == nullptr)</a>
<a name="978"><span class="lineNum">     978 </span>                :            :       return __last1;</a>
<a name="979"><span class="lineNum">     979 </span>                :            : </a>
<a name="980"><span class="lineNum">     980 </span>                :            :     // It is faster to compare from the first byte of __first1 even if we</a>
<a name="981"><span class="lineNum">     981 </span>                :            :     // already know that it matches the first byte of __first2: this is because</a>
<a name="982"><span class="lineNum">     982 </span>                :            :     // __first2 is most likely aligned, as it is user's &quot;pattern&quot; string, and</a>
<a name="983"><span class="lineNum">     983 </span>                :            :     // __first1 + 1 is most likely not aligned, as the match is in the middle of</a>
<a name="984"><span class="lineNum">     984 </span>                :            :     // the string.</a>
<a name="985"><span class="lineNum">     985 </span>                :            :     if (_Traits::compare(__first1, __first2, __len2) == 0)</a>
<a name="986"><span class="lineNum">     986 </span>                :            :       return __first1;</a>
<a name="987"><span class="lineNum">     987 </span>                :            : </a>
<a name="988"><span class="lineNum">     988 </span>                :            :     ++__first1;</a>
<a name="989"><span class="lineNum">     989 </span>                :            :   }</a>
<a name="990"><span class="lineNum">     990 </span>                :            : }</a>
<a name="991"><span class="lineNum">     991 </span>                :            : </a>
<a name="992"><span class="lineNum">     992 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="993"><span class="lineNum">     993 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="994"><span class="lineNum">     994 </span>                :            : __str_find(const _CharT *__p, _SizeT __sz,</a>
<a name="995"><span class="lineNum">     995 </span>                :            :        const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="996"><span class="lineNum">     996 </span>                :            : {</a>
<a name="997"><span class="lineNum">     997 </span>                :            :     if (__pos &gt; __sz)</a>
<a name="998"><span class="lineNum">     998 </span>                :            :         return __npos;</a>
<a name="999"><span class="lineNum">     999 </span>                :            : </a>
<a name="1000"><span class="lineNum">    1000 </span>                :            :     if (__n == 0) // There is nothing to search, just return __pos.</a>
<a name="1001"><span class="lineNum">    1001 </span>                :            :         return __pos;</a>
<a name="1002"><span class="lineNum">    1002 </span>                :            : </a>
<a name="1003"><span class="lineNum">    1003 </span>                :            :     const _CharT *__r = __search_substring&lt;_CharT, _Traits&gt;(</a>
<a name="1004"><span class="lineNum">    1004 </span>                :            :         __p + __pos, __p + __sz, __s, __s + __n);</a>
<a name="1005"><span class="lineNum">    1005 </span>                :            : </a>
<a name="1006"><span class="lineNum">    1006 </span>                :            :     if (__r == __p + __sz)</a>
<a name="1007"><span class="lineNum">    1007 </span>                :            :         return __npos;</a>
<a name="1008"><span class="lineNum">    1008 </span>                :            :     return static_cast&lt;_SizeT&gt;(__r - __p);</a>
<a name="1009"><span class="lineNum">    1009 </span>                :            : }</a>
<a name="1010"><span class="lineNum">    1010 </span>                :            : </a>
<a name="1011"><span class="lineNum">    1011 </span>                :            : </a>
<a name="1012"><span class="lineNum">    1012 </span>                :            : // __str_rfind</a>
<a name="1013"><span class="lineNum">    1013 </span>                :            : </a>
<a name="1014"><span class="lineNum">    1014 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1015"><span class="lineNum">    1015 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1016"><span class="lineNum">    1016 </span>                :            : __str_rfind(const _CharT *__p, _SizeT __sz,</a>
<a name="1017"><span class="lineNum">    1017 </span>                :            :               _CharT __c, _SizeT __pos) _NOEXCEPT</a>
<a name="1018"><span class="lineNum">    1018 </span>                :            : {</a>
<a name="1019"><span class="lineNum">    1019 </span>                :            :     if (__sz &lt; 1)</a>
<a name="1020"><span class="lineNum">    1020 </span>                :            :         return __npos;</a>
<a name="1021"><span class="lineNum">    1021 </span>                :            :     if (__pos &lt; __sz)</a>
<a name="1022"><span class="lineNum">    1022 </span>                :            :         ++__pos;</a>
<a name="1023"><span class="lineNum">    1023 </span>                :            :     else</a>
<a name="1024"><span class="lineNum">    1024 </span>                :            :         __pos = __sz;</a>
<a name="1025"><span class="lineNum">    1025 </span>                :            :     for (const _CharT* __ps = __p + __pos; __ps != __p;)</a>
<a name="1026"><span class="lineNum">    1026 </span>                :            :     {</a>
<a name="1027"><span class="lineNum">    1027 </span>                :            :         if (_Traits::eq(*--__ps, __c))</a>
<a name="1028"><span class="lineNum">    1028 </span>                :            :             return static_cast&lt;_SizeT&gt;(__ps - __p);</a>
<a name="1029"><span class="lineNum">    1029 </span>                :            :     }</a>
<a name="1030"><span class="lineNum">    1030 </span>                :            :     return __npos;</a>
<a name="1031"><span class="lineNum">    1031 </span>                :            : }</a>
<a name="1032"><span class="lineNum">    1032 </span>                :            : </a>
<a name="1033"><span class="lineNum">    1033 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1034"><span class="lineNum">    1034 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1035"><span class="lineNum">    1035 </span>                :            : __str_rfind(const _CharT *__p, _SizeT __sz,</a>
<a name="1036"><span class="lineNum">    1036 </span>                :            :         const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="1037"><span class="lineNum">    1037 </span>                :            : {</a>
<a name="1038"><span class="lineNum">    1038 </span>                :            :     __pos = _VSTD::min(__pos, __sz);</a>
<a name="1039"><span class="lineNum">    1039 </span>                :            :     if (__n &lt; __sz - __pos)</a>
<a name="1040"><span class="lineNum">    1040 </span>                :            :         __pos += __n;</a>
<a name="1041"><span class="lineNum">    1041 </span>                :            :     else</a>
<a name="1042"><span class="lineNum">    1042 </span>                :            :         __pos = __sz;</a>
<a name="1043"><span class="lineNum">    1043 </span>                :            :     const _CharT* __r = _VSTD::__find_end(</a>
<a name="1044"><span class="lineNum">    1044 </span>                :            :                   __p, __p + __pos, __s, __s + __n, _Traits::eq,</a>
<a name="1045"><span class="lineNum">    1045 </span>                :            :                         random_access_iterator_tag(), random_access_iterator_tag());</a>
<a name="1046"><span class="lineNum">    1046 </span>                :            :     if (__n &gt; 0 &amp;&amp; __r == __p + __pos)</a>
<a name="1047"><span class="lineNum">    1047 </span>                :            :         return __npos;</a>
<a name="1048"><span class="lineNum">    1048 </span>                :            :     return static_cast&lt;_SizeT&gt;(__r - __p);</a>
<a name="1049"><span class="lineNum">    1049 </span>                :            : }</a>
<a name="1050"><span class="lineNum">    1050 </span>                :            : </a>
<a name="1051"><span class="lineNum">    1051 </span>                :            : // __str_find_first_of</a>
<a name="1052"><span class="lineNum">    1052 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1053"><span class="lineNum">    1053 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1054"><span class="lineNum">    1054 </span>                :            : __str_find_first_of(const _CharT *__p, _SizeT __sz,</a>
<a name="1055"><span class="lineNum">    1055 </span>                :            :                 const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="1056"><span class="lineNum">    1056 </span>                :            : {</a>
<a name="1057"><span class="lineNum">    1057 </span>                :            :     if (__pos &gt;= __sz || __n == 0)</a>
<a name="1058"><span class="lineNum">    1058 </span>                :            :         return __npos;</a>
<a name="1059"><span class="lineNum">    1059 </span>                :            :     const _CharT* __r = _VSTD::__find_first_of_ce</a>
<a name="1060"><span class="lineNum">    1060 </span>                :            :         (__p + __pos, __p + __sz, __s, __s + __n, _Traits::eq );</a>
<a name="1061"><span class="lineNum">    1061 </span>                :            :     if (__r == __p + __sz)</a>
<a name="1062"><span class="lineNum">    1062 </span>                :            :         return __npos;</a>
<a name="1063"><span class="lineNum">    1063 </span>                :            :     return static_cast&lt;_SizeT&gt;(__r - __p);</a>
<a name="1064"><span class="lineNum">    1064 </span>                :            : }</a>
<a name="1065"><span class="lineNum">    1065 </span>                :            : </a>
<a name="1066"><span class="lineNum">    1066 </span>                :            : </a>
<a name="1067"><span class="lineNum">    1067 </span>                :            : // __str_find_last_of</a>
<a name="1068"><span class="lineNum">    1068 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1069"><span class="lineNum">    1069 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1070"><span class="lineNum">    1070 </span>                :<span class="lineCov">          1 : __str_find_last_of(const _CharT *__p, _SizeT __sz,</span></a>
<a name="1071"><span class="lineNum">    1071 </span>                :            :                const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="1072"><span class="lineNum">    1072 </span>                :            :     {</a>
<a name="1073"><span class="lineNum">    1073 </span>                :<span class="lineCov">          1 :     if (__n != 0)</span></a>
<a name="1074"><span class="lineNum">    1074 </span>                :            :     {</a>
<a name="1075"><span class="lineNum">    1075 </span>                :<span class="lineCov">          1 :         if (__pos &lt; __sz)</span></a>
<a name="1076"><span class="lineNum">    1076 </span>                :<span class="lineNoCov">          0 :             ++__pos;</span></a>
<a name="1077"><span class="lineNum">    1077 </span>                :            :         else</a>
<a name="1078"><span class="lineNum">    1078 </span>                :            :             __pos = __sz;</a>
<a name="1079"><span class="lineNum">    1079 </span>                :<span class="lineCov">         27 :         for (const _CharT* __ps = __p + __pos; __ps != __p;)</span></a>
<a name="1080"><span class="lineNum">    1080 </span>                :            :         {</a>
<a name="1081"><span class="lineNum">    1081 </span>                :<span class="lineCov">         27 :             const _CharT* __r = _Traits::find(__s, __n, *--__ps);</span></a>
<a name="1082"><span class="lineNum">    1082 </span>                :<span class="lineCov">         27 :             if (__r)</span></a>
<a name="1083"><span class="lineNum">    1083 </span>                :<span class="lineCov">          1 :                 return static_cast&lt;_SizeT&gt;(__ps - __p);</span></a>
<a name="1084"><span class="lineNum">    1084 </span>                :<span class="lineCov">         26 :         }</span></a>
<a name="1085"><span class="lineNum">    1085 </span>                :            :     }</a>
<a name="1086"><span class="lineNum">    1086 </span>                :<span class="lineNoCov">          0 :     return __npos;</span></a>
<a name="1087"><span class="lineNum">    1087 </span>                :<span class="lineCov">          1 : }</span></a>
<a name="1088"><span class="lineNum">    1088 </span>                :            : </a>
<a name="1089"><span class="lineNum">    1089 </span>                :            : </a>
<a name="1090"><span class="lineNum">    1090 </span>                :            : // __str_find_first_not_of</a>
<a name="1091"><span class="lineNum">    1091 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1092"><span class="lineNum">    1092 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1093"><span class="lineNum">    1093 </span>                :            : __str_find_first_not_of(const _CharT *__p, _SizeT __sz,</a>
<a name="1094"><span class="lineNum">    1094 </span>                :            :                     const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="1095"><span class="lineNum">    1095 </span>                :            : {</a>
<a name="1096"><span class="lineNum">    1096 </span>                :            :     if (__pos &lt; __sz)</a>
<a name="1097"><span class="lineNum">    1097 </span>                :            :     {</a>
<a name="1098"><span class="lineNum">    1098 </span>                :            :         const _CharT* __pe = __p + __sz;</a>
<a name="1099"><span class="lineNum">    1099 </span>                :            :         for (const _CharT* __ps = __p + __pos; __ps != __pe; ++__ps)</a>
<a name="1100"><span class="lineNum">    1100 </span>                :            :             if (_Traits::find(__s, __n, *__ps) == nullptr)</a>
<a name="1101"><span class="lineNum">    1101 </span>                :            :                 return static_cast&lt;_SizeT&gt;(__ps - __p);</a>
<a name="1102"><span class="lineNum">    1102 </span>                :            :     }</a>
<a name="1103"><span class="lineNum">    1103 </span>                :            :     return __npos;</a>
<a name="1104"><span class="lineNum">    1104 </span>                :            : }</a>
<a name="1105"><span class="lineNum">    1105 </span>                :            : </a>
<a name="1106"><span class="lineNum">    1106 </span>                :            : </a>
<a name="1107"><span class="lineNum">    1107 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1108"><span class="lineNum">    1108 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1109"><span class="lineNum">    1109 </span>                :            : __str_find_first_not_of(const _CharT *__p, _SizeT __sz,</a>
<a name="1110"><span class="lineNum">    1110 </span>                :            :                           _CharT __c, _SizeT __pos) _NOEXCEPT</a>
<a name="1111"><span class="lineNum">    1111 </span>                :            : {</a>
<a name="1112"><span class="lineNum">    1112 </span>                :            :     if (__pos &lt; __sz)</a>
<a name="1113"><span class="lineNum">    1113 </span>                :            :     {</a>
<a name="1114"><span class="lineNum">    1114 </span>                :            :         const _CharT* __pe = __p + __sz;</a>
<a name="1115"><span class="lineNum">    1115 </span>                :            :         for (const _CharT* __ps = __p + __pos; __ps != __pe; ++__ps)</a>
<a name="1116"><span class="lineNum">    1116 </span>                :            :             if (!_Traits::eq(*__ps, __c))</a>
<a name="1117"><span class="lineNum">    1117 </span>                :            :                 return static_cast&lt;_SizeT&gt;(__ps - __p);</a>
<a name="1118"><span class="lineNum">    1118 </span>                :            :     }</a>
<a name="1119"><span class="lineNum">    1119 </span>                :            :     return __npos;</a>
<a name="1120"><span class="lineNum">    1120 </span>                :            : }</a>
<a name="1121"><span class="lineNum">    1121 </span>                :            : </a>
<a name="1122"><span class="lineNum">    1122 </span>                :            : </a>
<a name="1123"><span class="lineNum">    1123 </span>                :            : // __str_find_last_not_of</a>
<a name="1124"><span class="lineNum">    1124 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1125"><span class="lineNum">    1125 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1126"><span class="lineNum">    1126 </span>                :            : __str_find_last_not_of(const _CharT *__p, _SizeT __sz,</a>
<a name="1127"><span class="lineNum">    1127 </span>                :            :                    const _CharT* __s, _SizeT __pos, _SizeT __n) _NOEXCEPT</a>
<a name="1128"><span class="lineNum">    1128 </span>                :            : {</a>
<a name="1129"><span class="lineNum">    1129 </span>                :            :     if (__pos &lt; __sz)</a>
<a name="1130"><span class="lineNum">    1130 </span>                :            :         ++__pos;</a>
<a name="1131"><span class="lineNum">    1131 </span>                :            :     else</a>
<a name="1132"><span class="lineNum">    1132 </span>                :            :         __pos = __sz;</a>
<a name="1133"><span class="lineNum">    1133 </span>                :            :     for (const _CharT* __ps = __p + __pos; __ps != __p;)</a>
<a name="1134"><span class="lineNum">    1134 </span>                :            :         if (_Traits::find(__s, __n, *--__ps) == nullptr)</a>
<a name="1135"><span class="lineNum">    1135 </span>                :            :             return static_cast&lt;_SizeT&gt;(__ps - __p);</a>
<a name="1136"><span class="lineNum">    1136 </span>                :            :     return __npos;</a>
<a name="1137"><span class="lineNum">    1137 </span>                :            : }</a>
<a name="1138"><span class="lineNum">    1138 </span>                :            : </a>
<a name="1139"><span class="lineNum">    1139 </span>                :            : </a>
<a name="1140"><span class="lineNum">    1140 </span>                :            : template&lt;class _CharT, class _SizeT, class _Traits, _SizeT __npos&gt;</a>
<a name="1141"><span class="lineNum">    1141 </span>                :            : inline _SizeT _LIBCPP_CONSTEXPR_AFTER_CXX11 _LIBCPP_INLINE_VISIBILITY</a>
<a name="1142"><span class="lineNum">    1142 </span>                :            : __str_find_last_not_of(const _CharT *__p, _SizeT __sz,</a>
<a name="1143"><span class="lineNum">    1143 </span>                :            :                          _CharT __c, _SizeT __pos) _NOEXCEPT</a>
<a name="1144"><span class="lineNum">    1144 </span>                :            : {</a>
<a name="1145"><span class="lineNum">    1145 </span>                :            :     if (__pos &lt; __sz)</a>
<a name="1146"><span class="lineNum">    1146 </span>                :            :         ++__pos;</a>
<a name="1147"><span class="lineNum">    1147 </span>                :            :     else</a>
<a name="1148"><span class="lineNum">    1148 </span>                :            :         __pos = __sz;</a>
<a name="1149"><span class="lineNum">    1149 </span>                :            :     for (const _CharT* __ps = __p + __pos; __ps != __p;)</a>
<a name="1150"><span class="lineNum">    1150 </span>                :            :         if (!_Traits::eq(*--__ps, __c))</a>
<a name="1151"><span class="lineNum">    1151 </span>                :            :             return static_cast&lt;_SizeT&gt;(__ps - __p);</a>
<a name="1152"><span class="lineNum">    1152 </span>                :            :     return __npos;</a>
<a name="1153"><span class="lineNum">    1153 </span>                :            : }</a>
<a name="1154"><span class="lineNum">    1154 </span>                :            : </a>
<a name="1155"><span class="lineNum">    1155 </span>                :            : template&lt;class _Ptr&gt;</a>
<a name="1156"><span class="lineNum">    1156 </span>                :            : inline _LIBCPP_INLINE_VISIBILITY</a>
<a name="1157"><span class="lineNum">    1157 </span>                :            : size_t __do_string_hash(_Ptr __p, _Ptr __e)</a>
<a name="1158"><span class="lineNum">    1158 </span>                :            : {</a>
<a name="1159"><span class="lineNum">    1159 </span>                :            :     typedef typename iterator_traits&lt;_Ptr&gt;::value_type value_type;</a>
<a name="1160"><span class="lineNum">    1160 </span>                :            :     return __murmur2_or_cityhash&lt;size_t&gt;()(__p, (__e-__p)*sizeof(value_type));</a>
<a name="1161"><span class="lineNum">    1161 </span>                :            : }</a>
<a name="1162"><span class="lineNum">    1162 </span>                :            : </a>
<a name="1163"><span class="lineNum">    1163 </span>                :            : template &lt;class _CharT, class _Iter, class _Traits=char_traits&lt;_CharT&gt; &gt;</a>
<a name="1164"><span class="lineNum">    1164 </span>                :            : struct __quoted_output_proxy</a>
<a name="1165"><span class="lineNum">    1165 </span>                :            : {</a>
<a name="1166"><span class="lineNum">    1166 </span>                :            :     _Iter  __first;</a>
<a name="1167"><span class="lineNum">    1167 </span>                :            :     _Iter  __last;</a>
<a name="1168"><span class="lineNum">    1168 </span>                :            :     _CharT  __delim;</a>
<a name="1169"><span class="lineNum">    1169 </span>                :            :     _CharT  __escape;</a>
<a name="1170"><span class="lineNum">    1170 </span>                :            : </a>
<a name="1171"><span class="lineNum">    1171 </span>                :            :     __quoted_output_proxy(_Iter __f, _Iter __l, _CharT __d, _CharT __e)</a>
<a name="1172"><span class="lineNum">    1172 </span>                :            :     : __first(__f), __last(__l), __delim(__d), __escape(__e) {}</a>
<a name="1173"><span class="lineNum">    1173 </span>                :            :     //  This would be a nice place for a string_ref</a>
<a name="1174"><span class="lineNum">    1174 </span>                :            : };</a>
<a name="1175"><span class="lineNum">    1175 </span>                :            : </a>
<a name="1176"><span class="lineNum">    1176 </span>                :            : _LIBCPP_END_NAMESPACE_STD</a>
<a name="1177"><span class="lineNum">    1177 </span>                :            : </a>
<a name="1178"><span class="lineNum">    1178 </span>                :            : _LIBCPP_POP_MACROS</a>
<a name="1179"><span class="lineNum">    1179 </span>                :            : </a>
<a name="1180"><span class="lineNum">    1180 </span>                :            : #endif  // _LIBCPP___STRING</a>
</pre>
      </td>
    </tr>
  </table>
  <br>

  <table width="100%" border=0 cellspacing=0 cellpadding=0>
    <tr><td class="ruler"><img src="../../../../../../../../../../glass.png" width=3 height=3 alt=""></td></tr>
    <tr><td class="versionInfo">Generated by: <a href="http://ltp.sourceforge.net/coverage/lcov.php" target="_parent">LCOV version 1.14</a></td></tr>
  </table>
  <br>

</body>
</html>
